comp.lang.idl-pvwave archive
Messages from Usenet group comp.lang.idl-pvwave, compiled by Paulo Penteado

Home » Public Forums » archive » CgBarPlot with NaNs?
Show: Today's Messages :: Show Polls :: Message Navigator
E-mail to friend 
Switch to threaded view of this topic Create a new topic Submit Reply
CgBarPlot with NaNs? [message #85756] Tue, 03 September 2013 04:43 Go to next message
rjp23 is currently offline  rjp23
Messages: 97
Registered: June 2010
Member
I'm using David's CgBarPlot routine and I have 4 data arrays I'd like to plot but one of them contains NaNs at the end which produces "infinite" bar heights.

If I truncate the NaNs from the array then the horizontal spacing then doesn't stay consistent with the other 4.

Is there a way around this?

Cheers
Re: CgBarPlot with NaNs? [message #85757 is a reply to message #85756] Tue, 03 September 2013 05:53 Go to previous messageGo to next message
David Fanning is currently offline  David Fanning
Messages: 11724
Registered: August 2001
Senior Member
rjp23@le.ac.uk writes:

> I'm using David's CgBarPlot routine and I have 4 data arrays I'd like to plot but one of them contains NaNs at the end which produces "infinite" bar heights.
>
> If I truncate the NaNs from the array then the horizontal spacing then doesn't stay consistent with the other 4.
>
> Is there a way around this?

I check for NaNs in cgBarPlot, but I wasn't following up with the data
display. Now the length of a bar with a NaN is set to 0. You can find an
updated version here:

http://www.idlcoyote.com/programs/cgbarplot.pro

I checked in changes to a number of Coyote Library programs today. It
may be time for a library update:

http:/www.idlcoyote.com/programs/zip_files/coyoteprograms.zi p

Cheers,

David
--
David Fanning, Ph.D.
Fanning Software Consulting, Inc.
Coyote's Guide to IDL Programming: http://www.idlcoyote.com/
Sepore ma de ni thue. ("Perhaps thou speakest truth.")
Re: CgBarPlot with NaNs? [message #85763 is a reply to message #85757] Wed, 04 September 2013 03:50 Go to previous message
rjp23 is currently offline  rjp23
Messages: 97
Registered: June 2010
Member
> I check for NaNs in cgBarPlot, but I wasn't following up with the data
>
> display. Now the length of a bar with a NaN is set to 0. You can find an
>
> updated version here:
>
>
>
> http://www.idlcoyote.com/programs/cgbarplot.pro
>

Excellent, thanks :-)
  Switch to threaded view of this topic Create a new topic Submit Reply
Previous Topic: parallel sign in postscript output in device fonts (direct graphics)
Next Topic: Y-axis problems using cgcontour

-=] Back to Top [=-
[ Syndicate this forum (XML) ] [ RSS ] [ PDF ]

Current Time: Wed Oct 08 13:31:57 PDT 2025

Total time taken to generate the page: 0.00611 seconds