Jackie - is the MATLAB code that you have posted above from the built-in MATLAB scatter function? Or is it something hat you have written? In the command window type
to see which implementations of this function exist. If more than one exists, then you may want to rename your function to not conflict with the built-in one.
As for the error, at line 55 the boolean allowNonNumeric is defined but allowNumeric is being passed into the getRealData function. If this is your code, then try modifying it to keep the variables consistent.