math.sin

The sine of angle, where the angle is in radians.

math.sin(const float angle) → const float
math.sin(input float angle) → input float
math.sin(series float angle) → series float
math.sin(simple float angle) → simple float
ParameterTypeRequiredDescription
angleconst floatyesThe angle, in radians. Use math.toradians to convert from degrees.

Returns const float or input float or series float or simple float — The sine, as a float in the argument’s form.

indicator("Sine")
plot(math.sin(math.pi / 2))

See also math.abs · math.acos · math.asin

Part of the function index.

Ready to put this into practice?
Try GoCharting Premium
Unlock advanced orderflow, market profile, options desk, and real-time data — everything you just read about, live in your charts.
Upgrade