Changeset 62f851f in sasview for fittingview/src/sans/perspectives/fitting/fitproblem.py
- Timestamp:
- Sep 30, 2011 2:11:23 PM (13 years ago)
- Branches:
- master, ESS_GUI, ESS_GUI_Docs, ESS_GUI_batch_fitting, ESS_GUI_bumps_abstraction, ESS_GUI_iss1116, ESS_GUI_iss879, ESS_GUI_iss959, ESS_GUI_opencl, ESS_GUI_ordering, ESS_GUI_sync_sascalc, costrafo411, magnetic_scatt, release-4.1.1, release-4.1.2, release-4.2.2, release_4.0.1, ticket-1009, ticket-1094-headless, ticket-1242-2d-resolution, ticket-1243, ticket-1249, ticket885, unittest-saveload
- Children:
- 647df0d1
- Parents:
- 2b440504
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
fittingview/src/sans/perspectives/fitting/fitproblem.py
r5e48acb r62f851f 43 43 :return: saved model 44 44 """ 45 def set_residuals(self, residuals): 46 """ 47 save a copy of residual 48 :param data: data selected 49 """ 50 def get_residuals(self): 51 """ 52 :return: residuals 53 """ 54 45 55 def set_theory_data(self, data): 46 56 """ … … 177 187 return smear object 178 188 """ 179 result = [] 180 if fid is None: 181 for value in self.itervalues(): 182 result.append(value.get_smearer()) 183 else: 184 if fid in self.iterkeys(): 185 result.append(self[fid].get_smearer()) 186 return result 189 if fid in self.iterkeys(): 190 return self[fid].get_smearer() 191 187 192 188 193 def save_model_name(self, name, fid=None): … … 227 232 """ 228 233 if fid in self.iterkeys(): 229 self[fid].get_model()234 return self[fid].get_model() 230 235 231 236 def set_fit_tab_caption(self, caption): … … 241 246 return self.fit_tab_caption 242 247 248 def set_residuals(self, residuals, fid): 249 """ 250 save a copy of residual 251 :param data: data selected 252 """ 253 if fid in self.iterkeys(): 254 self[fid].set_residuals(residuals) 255 256 def get_residuals(self, fid): 257 """ 258 :return: residuals 259 """ 260 if fid in self.iterkeys(): 261 return self[fid].get_residuals() 262 243 263 def set_theory_data(self, fid, data=None): 244 264 """ … … 434 454 self.fit_data = None 435 455 self.theory_data = None 456 self.residuals = None 436 457 # original data: should not be modified 437 458 self.original_data = None … … 509 530 """ 510 531 return self.model 511 532 533 def set_residuals(self, residuals): 534 """ 535 save a copy of residual 536 :param data: data selected 537 """ 538 self.residuals = residuals 539 540 def get_residuals(self): 541 """ 542 :return: residuals 543 """ 544 return self.residuals 545 512 546 def set_theory_data(self, data): 513 547 """
Note: See TracChangeset
for help on using the changeset viewer.