The AnalogOut widget sends values to hardware to continuously vary the output of a digital port. This is accomplished with PWM (Pulse Width Modulation), which rapidly switches the port on and off. This can vary the apparent brightness of an LED, or change the speed of a DC motor.
Be sure the port you select on your device supports PWM, because not all do. For example, on the Arduino, only the digital ports marked with a “~” are capable of PWM.