misaligned error bars if uneven datasets

Found a bug? Tell us about it here

Moderator: DPlotAdmin

Post Reply
Ashi
Posts: 28
Joined: Sun Dec 30, 2007 11:49 pm

misaligned error bars if uneven datasets

Post by Ashi »

When importing from excel, I had some cells which were blank due to having unknown error. E.g:
Y Error
1.1 0.4
1.2 0.6
1.7 0.3
1.8
1.9 0.4
3.4 0.5

When importing into dplot, the "blank" space is not imported. Now the error series has less datapoints.

When selecting the error series as the error, dplot does not check the x values, and instead simply matches the error bars by the index in the series, resulting in the error bars appearing on the wrong point.

(The 1.8 point gets the error bars from 1.9, 1.9 gets the error bars from 3.4, and the 3.4 value ends up with no error bars).

I think it would be better if the error bars were matched to data points by their x values, but if it's by index, then we should at least get a message saying "number of datapoints in series don't match" or something. Better yet, ideally a blank space in a dataset could be imported into dplot as a null value (right now I'm putting in error bars of "0" to get around the problem, but a null value would be preferable, with the idea being that no error bars would be shown for that point).
User avatar
DPlotAdmin
Posts: 2312
Joined: Tue Jun 24, 2003 9:34 pm
Location: Vicksburg, Mississippi
Contact:

Post by DPlotAdmin »

Better yet, ideally a blank space in a dataset could be imported into dplot as a null value (right now I'm putting in error bars of "0" to get around the problem, but a null value would be preferable,
How big is "null"? :-)

The mechanism for doing something similar is in there now (Options>Amplitude Limits), but is unfortunately ignored for error bar amplitudes. I'll change things such that if an error bar magnitude is outside those limits then no error bar is drawn.
Last edited by DPlotAdmin on Tue Nov 11, 2008 1:02 pm, edited 2 times in total.
Visualize Your Data
support@dplot.com
Ashi
Posts: 28
Joined: Sun Dec 30, 2007 11:49 pm

Post by Ashi »

How big is "null"? :-)
The same as the y value divided by 0 :-)

It should show no error bars if it's null :-)
User avatar
DPlotAdmin
Posts: 2312
Joined: Tue Jun 24, 2003 9:34 pm
Location: Vicksburg, Mississippi
Contact:

Post by DPlotAdmin »

I think you probably understand this, but just for anybody else who stumbles across this thread:

When you import data into DPlot it is stored into an array of real numbers. There's no such animal as "null". You *can* define an amplitude that DPlot will ignore with Options>Amplitude Limits, but outside of that option there's no way to say "this value is meaningless". In the next release the Amplitude Limits values will be honored for error bar magnitudes. That means that in your Excel spreadsheet you'll need to enter some bogus value instead of a blank cell.

I understand in your case you'd prefer to have the error value tied to a specific X, and in the case of importing all of the data from Excel in one pass that makes sense. But in general that can't work: you can, for example, import the X,Y data (no error values) from Excel, then copy/paste error values (no associated X) from some other source. In that case the "error" curve would have X values of 0,1,2,3,... and have no relationship to the curve that you want to assign error values to.
Visualize Your Data
support@dplot.com
Post Reply