Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.graphics.apps.gnuplot > #1254 > unrolled thread

plotting csv data with some empty regions

Started byadam.preble@gmail.com
First post2012-07-08 23:22 -0700
Last post2012-07-10 12:28 -0700
Articles 4 — 3 participants

Back to article view | Back to comp.graphics.apps.gnuplot


Contents

  plotting csv data with some empty regions adam.preble@gmail.com - 2012-07-08 23:22 -0700
    Re: plotting csv data with some empty regions antar3s86@gmail.com - 2012-07-09 05:40 -0700
      Re: plotting csv data with some empty regions adam.preble@gmail.com - 2012-07-10 07:12 -0700
        Re: plotting csv data with some empty regions sfeam <sfeam@users.sourceforge.net> - 2012-07-10 12:28 -0700

#1254 — plotting csv data with some empty regions

Fromadam.preble@gmail.com
Date2012-07-08 23:22 -0700
Subjectplotting csv data with some empty regions
Message-ID<4da4658a-e464-4abb-bb5f-d13b3494d958@googlegroups.com>
I was hoping to do a line plot for some time-domain data that looks something like this:

1,,
3,,
4,,
2,,
3,,
4,1,5
2,2,7
3,1,
2,1,
5,,

With:
plot 'stuff.csv' with lines

I get the first column fine.

Let's try:
plot 'stuff.csv' using 1:3 with lines
                                ^
         warning: Skipping data file with no valid points
                                                   ^
         x range is invalid

I am hoping for something that will start plotting the other lines when they become relevant, and stops plotting them as their data regions go stale again.  Is this readily possible?  I had pondered just popping in zeroes, but in the expanded set this becomes horrific to read; the chops when it transitions to/from zero make the plots useless.

[toc] | [next] | [standalone]


#1256

Fromantar3s86@gmail.com
Date2012-07-09 05:40 -0700
Message-ID<f13e41ea-4769-45f7-997b-28ce0521d315@googlegroups.com>
In reply to#1254
Am Montag, 9. Juli 2012 08:22:34 UTC+2 schrieb adam....@gmail.com:
> I was hoping to do a line plot for some time-domain data that looks something like this:
> 
> 1,,
> 3,,
> 4,,
> 2,,
> 3,,
> 4,1,5
> 2,2,7
> 3,1,
> 2,1,
> 5,,
> 
> With:
> plot 'stuff.csv' with lines
> 
> I get the first column fine.
> 
> Let's try:
> plot 'stuff.csv' using 1:3 with lines
>                                 ^
>          warning: Skipping data file with no valid points
>                                                    ^
>          x range is invalid
> 
> I am hoping for something that will start plotting the other lines when they become relevant, and stops plotting them as their data regions go stale again.  Is this readily possible?  I had pondered just popping in zeroes, but in the expanded set this becomes horrific to read; the chops when it transitions to/from zero make the plots useless.

You have to tell gnuplot what kind of separator you use:

set datafile separator ","

There you go ;)

[toc] | [prev] | [next] | [standalone]


#1259

Fromadam.preble@gmail.com
Date2012-07-10 07:12 -0700
Message-ID<df1716aa-e404-49a3-8f42-003d042ad3b5@googlegroups.com>
In reply to#1256
On Monday, July 9, 2012 7:40:43 AM UTC-5, (unknown) wrote:
> You have to tell gnuplot what kind of separator you use:
> 
> set datafile separator &quot;,&quot;
> 
> There you go ;)

Gah of course.

The plot isn't what I expect yet though.  I was hoping to see three lines going left to right, with some starting later and ending sooner than the line representing the first column.  Instead, I get one line that begins to jump around--including backwards.  Is there something else I need to specify to have it treat each column like it's own series?

[toc] | [prev] | [next] | [standalone]


#1262

Fromsfeam <sfeam@users.sourceforge.net>
Date2012-07-10 12:28 -0700
Message-ID<jthvpc$kb1$1@dont-email.me>
In reply to#1259
adam.preble@gmail.com wrote:

> On Monday, July 9, 2012 7:40:43 AM UTC-5, (unknown) wrote:
>> You have to tell gnuplot what kind of separator you use:
>> 
>> set datafile separator &quot;,&quot;
>> 
>> There you go ;)
> 
> Gah of course.
> 
> The plot isn't what I expect yet though.  I was hoping to see three lines
> going left to right, with some starting later and ending sooner than the
> line representing the first column.  Instead, I get one line that begins
> to jump around--including backwards.  Is there something else I need to
> specify to have it treat each column like it's own series?

  plot 'stuff.csv' using 1, '' using 2, '' using 3

or in the current gnuplot version

  plot for [N=1:3] 'stuff.csv' using N

[toc] | [prev] | [standalone]


Back to top | Article view | comp.graphics.apps.gnuplot


csiph-web