- Timestamp:
- Apr 23, 2009 10:20:12 AM (16 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:
- 2b63df0
- Parents:
- 8b31780
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
guiframe/local_perspectives/plotting/Plotter1D.py
r0b16ee3 r3b69ca6 16 16 import danse.common.plottools 17 17 from danse.common.plottools.PlotPanel import PlotPanel 18 from danse.common.plottools.plottables import Graph,Data1D,Theory1D,Data1D 18 from danse.common.plottools.plottables import Graph,Theory1D 19 from sans.guiframe import dataFitting 19 20 from sans.guicomm.events import EVT_NEW_PLOT 20 21 from sans.guicomm.events import StatusEvent ,NewPlotEvent,SlicerEvent,ErrorDataEvent … … 279 280 280 281 if selected_plot.__class__.__name__=="Data1D": 281 new_plot = Data1D(self.plots[self.graph.selected_plottable].x, 282 self.plots[self.graph.selected_plottable].y, 283 dy=dy) 284 else: 285 new_plot = Theory1D(self.plots[self.graph.selected_plottable].x, 286 self.plots[self.graph.selected_plottable].y, 287 dy=dy) 282 283 new_plot = dataFitting.Data1D( x=selected_plot.x, 284 y= selected_plot.y, 285 dx=selected_plot.dx, 286 dy=dy, 287 dxl=selected_plot.dxl, 288 dxw=selected_plot.dxw) 289 290 else: 291 new_plot = Theory1D(x=selected_plot.x,y=selected_plot.y,dy=dy) 288 292 new_plot.interactive = True 289 293 self.errors_hide = True … … 335 339 length = len(self.plots[self.graph.selected_plottable].x) 336 340 dy = numpy.zeros(length) 341 337 342 selected_plot= self.plots[self.graph.selected_plottable] 338 343 … … 350 355 ## Create a new plottable data1D 351 356 if selected_plot.__class__.__name__=="Data1D": 352 new_plot = Data1D(self.plots[self.graph.selected_plottable].x, 353 self.plots[self.graph.selected_plottable].y, 354 dy=dy) 357 new_plot = dataFitting.Data1D( x=selected_plot.x, 358 y= selected_plot.y, 359 dx=selected_plot.dx, 360 dy=dy, 361 dxl=selected_plot.dxl, 362 dxw=selected_plot.dxw) 355 363 else: 356 364 ## Create a new plottable Theory1D 357 new_plot = Theory1D(self.plots[self.graph.selected_plottable].x, 358 self.plots[self.graph.selected_plottable].y, 359 dy=dy) 365 new_plot = Theory1D(x=selected_plot.x,y=selected_plot.y,dy=dy) 366 360 367 new_plot.interactive = True 361 362 368 new_plot.name = self.plots[self.graph.selected_plottable].name 363 369 if hasattr(self.plots[self.graph.selected_plottable], "group_id"):
Note: See TracChangeset
for help on using the changeset viewer.