CASTREAL

Purpose:

Explicitly casts the input to a real value.

Syntax:

CASTREAL(val)

val

-

A scalar, series or table.

Returns:

A real value.

Example:

castreal(1)

 

returns the value 1.0.

Example:

castreal(0.2 + 8i)

 

returns the value 0.2.

Remarks:

CASTREAL is helpful when writing SPL functions that require an explicit real input and the type of the variable passed into the function may not be a real.

 

If the input to CASTREAL is a series, it will only operate on the first point of the series.

 

If the input to CASTREAL is a table, it will only operate on the first point in the first column of the table.

See Also:

CASTCOMPLEX

CASTINTEGER

CASTREAL

CASTSERIES

CASTSTRING

CASTWINDOW