matlabfcn
EvaluateMATLAB命令给MicrosoftExceldata
Syntax
Description
= matlabfcn(
specifies the MATLAB®command for evaluation in the MATLAB workspace, given the input datacommand
,inputs
)inputs
. Depending upon the MATLAB output,matlabfcn
returns a single value or string into the calling worksheet cell. If the result contains more than one value in MATLAB, only the first value in the array returns in the calling worksheet cell. Use this syntax when working in a worksheet cell.
Examples
Input Arguments
Tips
If
matlabfcn
fails, a standard Spreadsheet Link™ error displays by default; for example,#COMMAND
. To return MATLAB errors, useMLShowMatlabErrors
.执行一个马TLAB command that returns no data, use the
MLEvalString
function instead ofmatlabfcn
. In this case, write a command such asMLEvalString("function(" & A1 & ")")
, wherefunction
is the name of the function that returns no data andA1
is an input argument.