Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.graphics.apps.gnuplot > #1557
| From | Hans-Bernhard Bröker <HBBroeker@t-online.de> |
|---|---|
| Newsgroups | comp.graphics.apps.gnuplot |
| Subject | Re: timecolumns of different format, using clause timecolumn(n) with explicit format specifiers |
| Date | 2012-12-29 13:33 +0100 |
| Message-ID | <ak868cFdr7kU1@mid.dfncis.de> (permalink) |
| References | <50dedbca$0$6970$e4fe514c@news2.news.xs4all.nl> |
On 29.12.2012 13:02, Alex van der Spek wrote:
> I have a datafile like this:
>
> +++++++++++++
> Date Sunrise Sunset Daylength
> 1 December 2012, Saturday 08:28 16:34 08:05
> 2 December 2012, Sunday 08:29 16:33 08:03
> 3 December 2012, Monday 08:31 16:33 08:01
> 4 December 2012, Tuesday 08:32 16:32 08:00
> 5 December 2012, Wednesday 08:33 16:32 07:58
> 6 December 2012, Thursday 08:35 16:31 07:56
> 7 December 2012, Friday 08:36 16:31 07:55
> +++++++++++++
>
> Columns are separated by tab (\t) characters. Total of 4 columns.
>
> I want to plot the Daylength versus the date. This presents a problem,
> timefmt cannot be used as the columns have different formats.
Not so fast. timefmt is actually per-axis, i.e. you can
set xdata time
set ydata time
set timefmt x '%d %B %Y'
set timefmt x '%H:%M'
plot 'data' using 1:4
If that doesn't work out, you should probably try some variation of
plot 'data' u (strptime('%d %B %Y',strcolumn(1)):(strptime('%H:%M',
strcolumn(4))
> I am
> trying to use timecolumn(n) with an explicit format expression which is
> part of the using clause:
Sorry, but that really can't work. The {'format'} part of the using
specification only works for ordinary data. It doesn't mix with
time/date data at all.
Back to comp.graphics.apps.gnuplot | Previous | Next — Previous in thread | Next in thread | Find similar
timecolumns of different format, using clause timecolumn(n) with explicit format specifiers "Alex van der Spek" <zdoor@xs4all.nl> - 2012-12-29 13:02 +0100
Re: timecolumns of different format, using clause timecolumn(n) with explicit format specifiers Hans-Bernhard Bröker <HBBroeker@t-online.de> - 2012-12-29 13:33 +0100
Re: timecolumns of different format, using clause timecolumn(n) with explicit format specifiers "Alex van der Spek" <zdoor@xs4all.nl> - 2012-12-29 14:58 +0100
csiph-web