Why is probplot not plotting the reference line for one matrix column?
2 vues (au cours des 30 derniers jours)
Afficher commentaires plus anciens
Inputting a 1457x3 double matrix whose columns represent millimeter motion in 3D space, probplot is not plotting a reference line for the first column (lateral data). Why? (Removing this column, probplot works, so it appears limited to this data specifically.)
I have attached the DICOMallshifts data, the file created via csvwrite. Interestingly, WordPad is showing -0 whereas MATLAB simply has 0, (cf. screenshot below) ... Does this show that MATLAB is in fact treating the 0 as negative because of this line in my code redefining axes?
DICOMallshifts = cmtomm*...
[-InterfractionalElektaMotion(:,1) -InterfractionalElektaMotion(:,3) ...
InterfractionalElektaMotion(:,2)];
Are all the -0 data causing this error in probplot?
Here is the code generating the probplot figure:
figure
probplot(DICOMallshifts)
legend('show','Location','northwest')
Here is a screenshot showing the problem:
Discrepancy between MATLAB and data written to file:
0 commentaires
Réponses (1)
Massimo Zanetti
le 26 Jan 2017
The problem is not due to -0 (which is the same as 0). It seems that your data in the first column are not even close to be Gaussian distributed. If you plot the histrogram of the first column you see it has just a peak in 0.
3 commentaires
Massimo Zanetti
le 26 Jan 2017
Modifié(e) : Massimo Zanetti
le 26 Jan 2017
My suspect is that, having such a large number of same data (precisely many 0s) the line cannot be drawn because its angular coefficient is close to infinite (a vertical line cannot be defined as a function).
Inspect this:
x=linspace(0,1);
y=x*inf;
plot(x,y);
It throws no errors, but the line is not plotted.
Voir également
Produits
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!