Ticket #4349 (closed: fixed)

Opened 9 years ago

Last modified 5 years ago

Expose waterfall plot creation to Python

Reported by: Russell Taylor Owned by: Russell Taylor
Priority: major Milestone: Release 2.0
Component: MantidPlot Keywords:
Cc: Blocked By:
Blocking: Tester: Andrei Savici

Description (last modified by Russell Taylor) (diff)

See http://soft.proindependent.com/doc/manual-en/x6311.html#Python-WaterfallPlots :

The waterfall graph is ideal . The graph has a pseudo-3D effect, enabling you to see variations in the Z direction. Waterfall plots are ideal for comparing variations between multiple data sets created under similar conditions. A pseudo 3D effect is generated by applying an offset to all the data curves in a 2D plot layer. You can create and customize them using the functions below:

g = waterfallPlot(table("Table1"), (2, 3, 4))
l = g.activeLayer()
l.setWaterfallOffset(50, 20)# x/y offsets as % of the layer drawing area width/height
l.setWaterfallSideLines(True) # draw side lines for all the data curves
l.setWaterfallFillColor(Qt.lightGray)
g.reverseWaterfallOrder() # reverse the order of the displayed curves

Change History

comment:1 Changed 9 years ago by Russell Taylor

  • Description modified (diff)

comment:2 Changed 9 years ago by Russell Taylor

  • Status changed from new to accepted

comment:3 Changed 9 years ago by Russell Taylor

Expose waterfall plots to python. Re #4349.

Changeset: df1edf5c1df5d94f8378fee7a746aab42485eea4

comment:4 Changed 9 years ago by Russell Taylor

  • Status changed from accepted to verify
  • Resolution set to fixed

comment:5 Changed 9 years ago by Andrei Savici

  • Status changed from verify to verifying
  • Tester set to Andrei Savici

comment:6 Changed 9 years ago by Andrei Savici

In the installed version on Windows, when trying to convert to waterfall plot I encountered:

convertToWaterfall(g)
"AttributeError on line 8: "'NoneType' object has no attribute '_getHeldObject'" in file 'mantidplot.py' at line 385"

This happened with both new type and old type f python interfaces. More checking to be done

comment:7 Changed 9 years ago by Russell Taylor

Restore lost return type. Re #4349.

...and touch a MantidPlot test for the first time to check it.

Changeset: ab745ae8b6f550e5cdb4752794de7529e8c9653e

comment:8 Changed 9 years ago by Andrei Savici

  • Status changed from verifying to closed

Works

comment:9 Changed 5 years ago by Stuart Campbell

This ticket has been transferred to github issue 5196

Note: See TracTickets for help on using tickets.