mxCreateDoubleScalar (C)
Scalar, double-precision array initialized to specified value
C Syntax
#include "matrix.h" mxArray *mxCreateDoubleScalar(double value);
Description
Call mxCreateDoubleScalar
to create a scalar
mxArray
of type mxDouble
.
You can use mxCreateDoubleScalar
instead of
mxCreateDoubleMatrix
in the following situation.
Replace: | With: |
---|---|
pa = mxCreateDoubleMatrix(1, 1, mxREAL); *mxGetDoubles(pa) = value; |
pa = mxCreateDoubleScalar(value); |
Call mxDestroyArray
when you finish using the
mxArray
.
Input Arguments
Output Arguments
Version History
Introduced before R2006a