fix#
Purpose#
Round towards 0.
Format#
- y = fix(x)#
- Parameters:
x (NxK matrix or N-dimensional array) – data
- Returns:
y (NxK matrix or N-dimensional array) – contains the rounded elements of x.
Examples#
x = { 0.9,
-0.9,
2.7,
-2.7 };
y = fix(x);
print y;
0.0000000
0.0000000
2.0000000
-2.0000000