Matt,
This error can occur if your variable name is the same as a function name in Matlab. For instance, using the variable name disp and then trying to return this variable will generate this error. To fix this, choose variable names that are not reserved names used by Matlab. See the Matlab online help or user manual for a list of reserved function names.
Zvezdana S.
National Instruments