Ticket #3494 (closed: fixed)

Opened 9 years ago

Last modified 5 years ago

Mantid cannot plot 2 Workspaces with different units together

Reported by: Wenduo Zhou Owned by: Russell Taylor
Priority: major Milestone: Iteration 30
Component: MantidPlot Keywords:
Cc: Blocked By:
Blocking: Tester: Janik Zikovsky

Description

I tried to plot 2 Workspaces (each has one spectral) together. They were without unit. And they have different range on x-axis. I could plot each of them separately. But I failed to plot them together. I tried dragging one onto another. I tried selecting both of them and plotting the spectral. Neither worked.

Attachments

goft.dat (56.4 KB) - added by Wenduo Zhou 9 years ago.
importNomadIDLData.py (2.9 KB) - added by Wenduo Zhou 9 years ago.
NOM_1818ftf.gr (203.0 KB) - added by Wenduo Zhou 9 years ago.

Change History

Changed 9 years ago by Wenduo Zhou

Changed 9 years ago by Wenduo Zhou

Changed 9 years ago by Wenduo Zhou

comment:1 Changed 9 years ago by Wenduo Zhou

In order to reproduce what I found, please (1) use LoadAscii() to load goft.dat. (2) run importNomadIDLData.py. It will read NOM_1818ftf.gr stored in the same directory, and create a Workspace for it.

comment:2 Changed 9 years ago by Russell Taylor

This is to do with plotting curves from workspaces that have different units on top of one another. Look at Graph.cpp line 3286. If the units don't match it returns NULL from here which results in the curve (silently) not being added.

We should let people make nonsense plots if they want to! (and I'm sure what Wenduo was trying to do wasn't nonsense).

comment:3 Changed 9 years ago by Russell Taylor

  • Status changed from new to accepted
  • Owner set to Russell Taylor

comment:4 Changed 9 years ago by Russell Taylor

In [13758]:

Don't prevent people from overlaying plots of data with different units (just print a warning instead). Re #3494.

comment:5 Changed 9 years ago by Russell Taylor

  • Status changed from accepted to verify
  • Resolution set to fixed
  • Component changed from Mantid to MantidPlot
  • Summary changed from Mantid cannot plot 2 Workspaces together to Mantid cannot plot 2 Workspaces with different units together

comment:6 Changed 9 years ago by Janik Zikovsky

  • Status changed from verify to verifying
  • Tester set to Janik Zikovsky

comment:7 Changed 9 years ago by Janik Zikovsky

  • Status changed from verifying to closed

Works as advertised. A+++

comment:8 Changed 5 years ago by Stuart Campbell

This ticket has been transferred to github issue 4341

Note: See TracTickets for help on using tickets.