Put variable into MATLAB engine workspace
#include "engine.h" int engPutVariable(Engine *ep, const char *name, const mxArray *pm);
#include "engine.h" integer*4 engPutVariable(ep, name, pm) mwPointer ep, pm character*(*) name
mxArray in the engine workspace
0 if successful and
an error occurs.
ep, giving it the variable name
mxArray does not exist in the workspace,
the function creates it. If an
mxArray with the
same name exists in the workspace, the function replaces the existing
The limit for the size of data transferred is 2 GB.
Do not use MATLAB® function names for variable names.
Common variable names that conflict with function names include
To determine whether a particular name is associated with a MATLAB function,
The engine application owns the original
is responsible for freeing its memory. Although the
sends a copy of the
mxArray to the MATLAB workspace,
the engine application does not need to account for or free memory
for the copy.
following examples in