Learn R Programming

astrolibR (version 0.1)

cirrange: Force an angle into the range 0

Description

Force an angle into the range 0

Usage

cirrange(ang, radians=FALSE)

Arguments

ang
angle, scalar or vector
radians
indicates that angle is specified in radians rather than decimal degrees (optional, default = FALSE)

Value

ang
transformed angle

Details

The input angle is transformed into the range 0 to +360 degrees (or 0 to 2*pi for radians). This function is used by several other astrolib functions, and is rarely used directly by the user.

Examples

Run this code
new_ang <- cirrange(-40.)   # returns 320.  

Run the code above in your browser using DataLab