ATan(x:Num, [y:Num]):Num

Returns the arc-tangent of x resp. x/y. The angle is returned in degrees (not radians as many other programming languages), and is in the range [0,360).

A heading angle is computed as

   angle := ATan(Waypoint.DX, Waypoint.DY)

This form is better than

   angle := ATan(Waypoint.DX / Waypoint.DY)

because it gets the quadrant right, and does not divide by zero if Waypoint.DX is 0.

If any parameter is EMPTY, or if both parameters are 0, returns EMPTY.

Since: PCC 0.98.3, PCC2 1.99.8

This is a testing version.
It may be incomplete, and have more bugs (or features) than the public live version at planetscentral.com.