Changes in src/sas/sasgui/guiframe/dataFitting.py [68adf86:0d64713] in sasview
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
src/sas/sasgui/guiframe/dataFitting.py
r68adf86 r0d64713 17 17 """ 18 18 """ 19 20 def __init__(self, x=None, y=None, dx=None, dy=None, lam=None, dlam=None, isSesans=False): 19 def __init__(self, x=None, y=None, dx=None, dy=None): 21 20 """ 22 21 """ … … 25 24 if y is None: 26 25 y = [] 27 self.isSesans = isSesans 28 PlotData1D.__init__(self, x, y, dx, dy, lam, dlam) 29 LoadData1D.__init__(self, x, y, dx, dy, lam, dlam, isSesans) 30 26 PlotData1D.__init__(self, x, y, dx, dy) 27 LoadData1D.__init__(self, x, y, dx, dy) 31 28 self.id = None 32 29 self.list_group_id = [] … … 35 32 self.path = None 36 33 self.xtransform = None 37 if self.isSesans:38 self.xtransform = "x"39 34 self.ytransform = None 40 if self.isSesans:41 self.ytransform = "y"42 35 self.title = "" 43 36 self.scale = None … … 75 68 # First, check the data compatibility 76 69 dy, dy_other = self._validity_check(other) 77 result = Data1D(x=[], y=[], lam=[], dx=None, dy=None, dlam=None)70 result = Data1D(x=[], y=[], dx=None, dy=None) 78 71 result.clone_without_data(length=len(self.x), clone=self) 79 72 result.copy_from_datainfo(data1d=self) … … 122 115 # First, check the data compatibility 123 116 self._validity_check_union(other) 124 result = Data1D(x=[], y=[], lam=[], dx=None, dy=None, dlam=None)117 result = Data1D(x=[], y=[], dx=None, dy=None) 125 118 tot_length = len(self.x) + len(other.x) 126 119 result = self.clone_without_data(length=tot_length, clone=result) 127 if self.dlam == None or other.dlam is None:128 result.dlam = None129 else:130 result.dlam = numpy.zeros(tot_length)131 120 if self.dy == None or other.dy is None: 132 121 result.dy = None … … 152 141 result.y = numpy.append(self.y, other.y) 153 142 result.y = result.y[ind] 154 result.lam = numpy.append(self.lam, other.lam)155 result.lam = result.lam[ind]156 if result.dlam != None:157 result.dlam = numpy.append(self.dlam, other.dlam)158 result.dlam = result.dlam[ind]159 143 if result.dy != None: 160 144 result.dy = numpy.append(self.dy, other.dy) … … 276 260 # First, check the data compatibility 277 261 self._validity_check_union(other) 278 result = Data1D(x=[], y=[], lam=[], dx=None, dy=None, dlam=[])262 result = Data1D(x=[], y=[], dx=None, dy=None) 279 263 tot_length = len(self.x)+len(other.x) 280 264 result.clone_without_data(length=tot_length, clone=self) 281 if self.dlam == None or other.dlam is None:282 result.dlam = None283 else:284 result.dlam = numpy.zeros(tot_length)285 265 if self.dy == None or other.dy is None: 286 266 result.dy = None … … 305 285 result.y = numpy.append(self.y, other.y) 306 286 result.y = result.y[ind] 307 result.lam = numpy.append(self.lam, other.lam)308 result.lam = result.lam[ind]309 287 if result.dy != None: 310 288 result.dy = numpy.append(self.dy, other.dy)
Note: See TracChangeset
for help on using the changeset viewer.