MCPcopy Create free account
hub / github.com/NSLS2/PyXRF / data_for_plot

Method data_for_plot

pyxrf/model/parameters.py:1132–1157  ·  view source on GitHub ↗

Save data in terms of K, L, M lines for plot.

(self)

Source from the content-addressed store, hash-verified

1130 self.param_new["non_fitting_values"]["escape_ratio"] = 0.0
1131
1132 def data_for_plot(self):
1133 """
1134 Save data in terms of K, L, M lines for plot.
1135 """
1136 self.total_y = None
1137 self.auto_fit_all = {}
1138
1139 for k, v in self.EC.element_dict.items():
1140 if v.status is True:
1141 self.auto_fit_all[k] = v.spectrum
1142 if self.total_y is None:
1143 self.total_y = np.array(v.spectrum) # need to copy an array
1144 else:
1145 self.total_y += v.spectrum
1146
1147 # for k, v in new_dict.items():
1148 # if '-' in k: # pileup
1149 # self.total_pileup[k] = self.EC.element_dict[k].spectrum
1150 # elif 'K' in k:
1151 # self.total_y[k] = self.EC.element_dict[k].spectrum
1152 # elif 'L' in k:
1153 # self.total_l[k] = self.EC.element_dict[k].spectrum
1154 # elif 'M' in k:
1155 # self.total_m[k] = self.EC.element_dict[k].spectrum
1156 # else:
1157 # self.total_y[k] = self.EC.element_dict[k].spectrum
1158
1159 def get_user_peak_list(self):
1160 """

Calls 1

itemsMethod · 0.80

Tested by

no test coverage detected