Error: "Index indices must be either real positive integers or boolean" when using the Matlab.NET builder

I am using matlab NE builder to compile a DLL file that I am calling from C #. Confirmed that the Matlab code works in matlab, but the error occurs when calling cc:

An unhandled exception of type 'System.Exception' occurred in MWArray.dll

Additional Information:

... MWMCR :: EvaluateFunction error ... Indexes of indexes must either be real integers or logical targets. Error in => KalmanFilter.m at line 108.

The relevant line is as follows:

plot(data(:, 1), data(:, 2));

      

I have confirmed that when the line is reached, the variable data is n by 4, with n> 50, why the statement should make sense.

Anyone have any experience? thanks in advance

+3


source to share


1 answer


As far as I know, this problem occurs when you call variables by function names or MatLAB functions (reserved names). Make sure this isn't happening.



+4


source







All Articles