- Timestamp:
- Sep 17, 2009 9:59:25 AM (15 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:
- e5664f2
- Parents:
- 920a6e5
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
sansview/perspectives/fitting/fitting.py
r104f3da rb2f4f83 277 277 @param return 278 278 """ 279 279 detector=None 280 source=None 280 281 info = None 281 282 id=None 282 283 dxl=None 284 dxw=None 285 dx=None 286 if hasattr(item, "dxl"): 287 dxl = copy.deepcopy(item.dxl) 288 if hasattr(item, "dxw"): 289 dxw = copy.deepcopy(item.dxw) 290 if hasattr(item, "detector"): 291 detector = copy.deepcopy(item.detector) 292 if hasattr(item, "source"): 293 source = copy.deepcopy(item.source) 283 294 if hasattr(item ,"info"): 284 295 info= copy.deepcopy(item.info) 285 296 if hasattr(item,"id"): 286 297 id = copy.deepcopy(item.id) 287 288 data= Data1D(x=item.x, y=item.y,dx=None, dy=None) 289 data.copy_from_datainfo(item) 290 item.clone_without_data(clone=data) 291 data.dy= dy 298 if hasattr(item, "dx"): 299 dx= item.dx 300 301 302 data= Data1D(x=item.x, y=item.y,dx=dx, dy=dy) 303 data.dxl = dxl 304 data.dxw = dxw 305 292 306 data.name = item.name 293 307 if detector!=None: 308 data.detector = detector 309 if source!=None: 310 data.source = source 294 311 ## allow to highlight data when plotted 295 312 data.interactive = copy.deepcopy(item.interactive) … … 299 316 ## to save data 1D as cansas xml file 300 317 data.info= info 318 ## If the data file does not tell us what the axes are, just assume... 319 data.xaxis(copy.deepcopy(item._xaxis),copy.deepcopy(item._xunit)) 320 data.yaxis(copy.deepcopy(item._yaxis),copy.deepcopy(item._yunit)) 321 301 322 data.group_id = item.group_id 302 323 return data
Note: See TracChangeset
for help on using the changeset viewer.