Previous PageNext Page

7.20.5 atan2 Method

Returns the angle (in radians) from the X axis to a point (y,x).
 

Syntax

Math.atan2(y, x)

Arguments

x
A numeric expression representing the cartesian x-coordinate. Required.
y
A numeric expression representing the cartesian y-coordinate. Required.

Remarks

The return value is between -pi and pi, representing the angle of the supplied (y,x) point.
 

Copyright © 2000 Chili!Soft

Previous PageTop Of PageNext Page