[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

*Subject*: Re: IDL messes up Julian day plots ?*From*: Tom McGlynn <tam(at)silk.gsfc.nasa.gov>*Date*: Fri, 02 Oct 1998 15:06:20 -0400*Newsgroups*: comp.lang.idl-pvwave*Organization*: NASA Goddard Space Flight Center -- Greenbelt, Maryland USA*References*: <Pine.OSF.3.95.981002183635.30950A-100000@poseidon.ifctr.mi.cnr.it>*Xref*: news.doit.wisc.edu comp.lang.idl-pvwave:12354

Plotting is done using only single precision arithmetic, but you should be OK over a two-year span. Your talking about an interval of 900 seconds over a span of 6x10^7 or ~.0001 which is well within the resolution of a real. It's a little kludgy, but you could do something like common mydates, time0 time0 = times(0) times = times-time0 plot, times, ..., xtickformat='NEWlabel_date' with function NEWlabel_date, axis, index, value common mydates, time0 return, label_date,axis,index,value+time0 end Since you've gotten rid of a potentially large offset value in the plotting you should get the full benefit of single precision, but are still able to label things appropriately. Tom McGlynn tam@silk.gsfc.nasa.gov LC's No-Spam Newsreading account wrote: > > I have a 2-year-long list of samples, one sample every 15 min. > The times are stored in Unix format (integer seconds since 1970). > > I want to plot this using label_date to annotate the x axis. I do > > ; convert to julian days > times=double(a.data.time) > times=times/86400. > times=times + julday(1,1,1970) > > dummy=label_date(date_format='%D %M') > plot,times,a.data.nitem ,xtickformat='label_date' > > If I restrict the plot to shorter periods e.g. > plot,times(u),a.data(u).nitem ,xtickformat='label_date' > > I get that several points are plotted at the same abscissa (x coordinate) > even if the values of a.data.time and times are distinct. > > It looks like the plotting routines are unable to scale double precision > values correctly. On the other hand I'd say I need such precision with "large" > numbers like dates in julian days. And I need julian days to use label_date. > > Any clue ? >

**References**:**IDL messes up Julian day plots ?***From:*LC's No-Spam Newsreading account

- Prev by Date:
**IDL messes up Julian day plots ?** - Next by Date:
**Re: Would you consider this a bug?** - Prev by thread:
**IDL messes up Julian day plots ?** - Next by thread:
**Restored Object Method Compilation** - Index(es):