StollLab / EasySpin

MATLAB toolbox for Electron Paramagnetic Resonance (EPR) spectroscopy
http://easyspin.org
MIT License
48 stars 25 forks source link

pepper/salt/etc: structure as third output #299

Closed stestoll closed 10 months ago

stestoll commented 10 months ago

Currently, pepper and salt return a list of transitions as the third output (if requested). This is a bit limiting.

They should return a structure as the third output, which then contains one field for the transitions, and other fields with other information.

[B,spc,out] = pepper(Sys,Exp,Opt);
% gives out.Trans or similar, and other fields

This would also help with compatibility going forward, even if we don't introduce any additional fields at this time.

This could also apply to the last output of resfields and related functions

saffron already returns a structure as third output.

garlic and chili do not return third outputs at the moment.

curry has an output argument list that depends on what the user asks it to calculate.

cardamom returns the time-domain signal as third output. This should also be converted to a field in a structure.