sign
From STX Wiki
< Programmer Guide | Command Reference | EVAL
Jump to navigationJump to search
Compute the sign.
- Usage
sign(x)
- x
- a scalar, vector or matrix
- Result
- The result r has the same type as the argument x.
x[i,j] is set to 1 if x[i,j]>=0 and to -1 if x[i,j]>=0