Refactoring #2093

GUI: plots: create prototype of universal 1D, 2D plot machinery

Added by pospelov over 2 years ago. Updated 2 months ago.

Status:BacklogStart date:20 Jun 2018
Priority:NormalDue date:
Assignee:-% Done:

0%

Category:-
Target version:-

Description

For the moment we have IntensityDataItem and SpecularDataItem which are used to plot 1D and 2D results of simulation/fitting. This is done in a family of widgets (ScientificPlot and Co).
I see two problems in the code:

  • IntensityDataItem and SpecularDataItem carries the knowledge not only about the data to plot, but also about neutron scattering (Instrument, Q-space etc).
  • Lots of code are duplicated

For example, fit comparison widgets for specular simulation and profile widget for 2D GISAS do the same, but are implemented in very different way.

Within this item I suggest to write prototype of mini-machinery (family of SessionItem classes and corresponding views) intended only for scientific 1D and 2D plotting.
As soon as it is done, we will be able to rewrite out IntensityDataItems and Co in more decoupled way.

Here will be the list of items to implement in mini-framework.
  • 1D plot on canvas.
  • Many 1D plot on canvas, with different color, line type, title and the legend.
  • 1D plot on canvas with variable bin axis.
  • Color map for 2D data.
  • 2D data and its projections.
  • Synchronized axes between several plots.
  • To be extended...

Related issues

Related to BornAgain - Refactoring #2109: GUI: plots: refactor 1D and 2D plotting Backlog 12 Jul 2018

History

#1 Updated by wuttke 2 months ago

  • Subject changed from GUI: create prototype of universal 1D, 2D plot machinery to GUI: plots: create prototype of universal 1D, 2D plot machinery

#2 Updated by wuttke 2 months ago

Also available in: Atom PDF