nanzero(
nanzero(
VALUE
)

The nanzero( function converts invalid numeric values into zero.

Parameters

This function has one parameter:

value – floating point value or expression

Description

This function converts invalid numeric values into zero. What is an invalid number, you ask? Some examples would include anything divided by zero or the square root of a negative number.

    nanzero(5/2) ☞ 2.5
    nanzero(5/0) ☞ 0
    nanzero(sqr(8)) ☞  2.82842712474619
    nanzero(sqr(-8)) ☞ 0

See Also

- / -- divides one numeric value by another.
- cos( -- calculates the cosine of an angle.
- degree -- tells Panorama that all angles input to and calculated in trigonometric functions are in degrees rather than radians.
- degrees2radians( -- converts an angle from degrees to radians.
- degreestoradians( -- converts an angle from degrees into radians
- info("angleunits") -- returns the current angular measurement units.
- latlongdistance( -- calculates the distance between two points on the earth (or any other sphere).
- nan( -- checks to see if a numeric value is invalid.
- nanerror( -- converts invalid numeric values into an error.
- radian -- tells Panorama that all angles in trigonometric functions should be calculated using radians rather than degrees.
- radians2degrees( -- converts an angle from radians to degrees.
- radianstodegrees( -- converts an angle from radians to degrees.
- sin( -- calculates the sine of an angle.
- sqr( -- calculates the square root of a value.
- tan( -- calculates the tangent of an angle.
- validnumber( -- checks to see if a numeric value is valid.

History

Version | Status | Notes
10.2 | New | New in this version