becquerel
becquerel copied to clipboard
Fitter.custom_plot fails if roi is not defined
I currently get this error:
becquerel/core/fitting.py in custom_plot(self, title, savefname, title_fontsize, title_fontweight, residual_type, **kwargs)
913 param_name, v, e, np.abs(e / v))
914 # Add info about the ROI and units
--> 915 s += 'ROI: [{0:.3f}, {1:.3f}]\n'.format(*self.roi)
916 s += 'X units: {:s}\n'.format(self.xmode if self.xmode else 'None')
917 s += 'Y units: {:s}\n'.format(self.ymode if self.ymode else 'None')
TypeError: format() argument after * must be an iterable, not NoneType
if I don't provide the roi
kwarg to Fitter.__init__
. Temporary fix is to use roi=[0, np.inf]
. Seems like by adding ROI to the custom_plot output we require this to be populated.