Scatter plot undefined variable
6 views (last 30 days)
Show older comments
Jackie Yang on 14 Aug 2019
Commented: Jackie Yang on 15 Aug 2019
Hi, i just started using Matlab for a personal project, I don't have any experience with it.
I'v tried to plot scatter plots with 3 different appropriate data sets and they all get the same error:
This is the same for every data set that I use...
Can i please get some help trying to fix this? Here's line 56
Geoff Hayes on 14 Aug 2019
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
which scatter -all
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.
More Answers (1)
Andrey Kiselnikov on 14 Aug 2019
Edited: Andrey Kiselnikov on 14 Aug 2019
"allowNonNumeric" and "allowNumeric" are different variables, you defined first one and forgot last one (I assume this is mistake).
Good reference with ready to try examples is here
If my help was useful please mark this answer as accepted.
Find more on Scatter Plots in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!Start Hunting!