Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.graphics.apps.gnuplot > #1111 > unrolled thread
| Started by | bryan <bryanlepore@gmail.com> |
|---|---|
| First post | 2012-05-15 10:15 -0700 |
| Last post | 2012-05-15 11:14 -0700 |
| Articles | 3 — 2 participants |
Back to article view | Back to comp.graphics.apps.gnuplot
time format and xrange or missing data "." bryan <bryanlepore@gmail.com> - 2012-05-15 10:15 -0700
Re: time format and xrange or missing data "." Hans-Bernhard Bröker <HBBroeker@t-online.de> - 2012-05-15 19:52 +0200
Re: time format and xrange or missing data "." bryan <bryanlepore@gmail.com> - 2012-05-15 11:14 -0700
| From | bryan <bryanlepore@gmail.com> |
|---|---|
| Date | 2012-05-15 10:15 -0700 |
| Subject | time format and xrange or missing data "." |
| Message-ID | <11080488.2800.1337102142460.JavaMail.geo-discussion-forums@ynmb39> |
[ gnuplot 4.6 patchlevel 0 ]
trying to understand use of 'set xdata time' vis-a-vis the following points:
I would like to set xrange longer than the available data. I used a "." to mark missing data points. I can plot the first field (see below) using a conventional x/y data setup and various xranges (not shown). however when using 'set xdata time' it appears that this will not work. Note that I have the date in field 2, but this shouldn't matter I think. here are the commands:
gnuplot> set xdata time ; set timefmt '%m-%Y' ; set format x '%b'
gnuplot> plot 'data.dat' u 2:1 w lp
( ... looks OK ...)
gnuplot> set xrange [0:14]
gnuplot> replot
gnuplot> plot 'data.dat' u 2:1 w lp
all points y value undefined!
gnuplot> show xrange
set xdata time
set xrange [ * : * ] noreverse nowriteback # (currently ["10-2011":"05-2012"] )
data.dat:
8.38 11-2011
1.58 12-2011
3.13 01-2012
9.74 02-2012
2.78 03-2012
6.51 04-2012
4.43 05-2012
. 06-2012
. 07-2012
. 08-2012
. 09-2012
. 10-2012
. 11-2012
. 12-2012
-Bryan
[toc] | [next] | [standalone]
| From | Hans-Bernhard Bröker <HBBroeker@t-online.de> |
|---|---|
| Date | 2012-05-15 19:52 +0200 |
| Message-ID | <a1fjebFjl7U1@mid.dfncis.de> |
| In reply to | #1111 |
On 15.05.2012 19:15, bryan wrote: > I would like to set xrange longer than the available data. > gnuplot> set xdata time ; set timefmt '%m-%Y' ; set format x '%b' > gnuplot> plot 'data.dat' u 2:1 w lp > > ( ... looks OK ...) > > gnuplot> set xrange [0:14] How do you expect that to work for a time? What time/date is '14' supposed to be? If you're going to use time/date axes, your range will have to be in time/date format, too. Gnuplot even, kinda-sorta, tells you so: > gnuplot> show xrange > > set xdata time > set xrange [ * : * ] noreverse nowriteback # (currently ["10-2011":"05-2012"] ) Note that "currently" setting. That's how you're supposed to spell a setting of the xrange in this case.
[toc] | [prev] | [next] | [standalone]
| From | bryan <bryanlepore@gmail.com> |
|---|---|
| Date | 2012-05-15 11:14 -0700 |
| Message-ID | <29945450.29.1337105681688.JavaMail.geo-discussion-forums@ynia9> |
| In reply to | #1112 |
Gah - of course, that makes sense. I'll try it. Thanks.
[toc] | [prev] | [standalone]
Back to top | Article view | comp.graphics.apps.gnuplot
csiph-web