When levelsplot()
used with Opt.StickSpectrum=true
, the follow errors are throwed when mouse is moved over figure window:
Invalid or deleted object.
Error in levelsplot
Error while evaluating Figure WindowButtonMotionFcn
No lines are highlited, of course.
It seems to be a bug.
levelsplot() funcction with StickSpectrum
levelsplot() funcction with StickSpectrum
-
- EasySpin Creator
- Posts: 1106
- Joined: Mon Jul 21, 2014 10:11 pm
- Location: University of Washington
Re: levelsplot() funcction with StickSpectrum
This is indeed a bug, thanks for reporting!
Re: levelsplot() funcction with StickSpectrum
It seems that is more general problem. The error occures after the changing of spin system regardless drawing of the stick spectrum.
Only reboot of MATLAB solves the problem. Neither clearing of the figure nor its closing have no effect.
I hope it will be useful.
My system is Win10, MATLAB 2022a, EasySpin 6.0.6
Here the script:
clear, clf
Sys.S = 1/2;
Sys.Nucs='55Mn';
Sys.g=2.001;
Sys.A=mt2mhz(200)/10;
mwFreq=9.6;
Par.PlotThreshold=1e-3;
%Par.SlopeColor = true;
%Par.StickSpectrum = true;
B = [280 400]; % mT
levelsplot(Sys,'x',B,mwFreq,Par);
Just replace Sys.Nucs='55Mn'
to Sys.Nucs='63Cu'
and back.
-
- EasySpin Creator
- Posts: 1106
- Joined: Mon Jul 21, 2014 10:11 pm
- Location: University of Washington
Re: levelsplot() funcction with StickSpectrum
Thanks for reporting! Indeed, this seems to be a bug that needs a bit more work to fix. Please post an issue here: https://github.com/StollLab/EasySpin/issues
Re: levelsplot() funcction with StickSpectrum
The bug does not seem to be reproducible. I cannot find unambiguous conditions when it occurs.
Also there is a minor bug with linewidths of transitions at levelsplot diagram. They are initially thicker than ones after mouse hilighting.