Wrap a Scilab variable in using systematically Numpy.
X = pyNpWrap(x [, byCopy])
Wrappable Scilab data.
A boolean.
A Python object
The Scilab data are wrapped with a Numpy array (even for matrix 1x1). When byCopy is set to false, the Numpy array will use and a keep a C pointer on the Scilab data, this is why it should be uesd very carefully.
pyUseScilabIndex(%t); a = zeros(3, 3); A = pyNpWrap(a, %f); // We modify a and look at A a(2, 2) = 1234; A // We modify A (in using the Scilab way to index) A(3, 3) = 4321; a pyRemove numpy A | ![]() | ![]() |
Version | Description |
5.4.0 | Python module. |