[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [O] using gnuplot's "splot" and "every" commands on org-mode table d
From: |
Eric Schulte |
Subject: |
Re: [O] using gnuplot's "splot" and "every" commands on org-mode table data |
Date: |
Fri, 17 May 2013 14:39:54 -0600 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/24.3 (gnu/linux) |
Paul Stansell <address@hidden> writes:
> Hi Eric,
>
> Thanks for your work on this. I've tried your latest changes and I
> think they're a big improvement.
>
> I've attached another org-mode file for you to try. It illustrates
> the use of double blank lines in the first table (called block_data)
> to inform gnuplot that there're two separate data sets in the single
> data file. The first code block (gnuplot_1) plots these two data sets
> as red and green surfaces. It's really nice that gnuplot can now be
> used in this way from within org-mode.
>
> One slight drawback, however, is that there still doesn't seem to be a
> way to specify missing values in the org table in the way they're
> frequently used by gnuplot. An illustration of what I mean by this is
> given in the table block_data_missing in the attached org file.
> You'll see that I've inserted two '?' characters for missing z-values.
> If you execute the second and third code blocks (gnuplot_2 and
> gnuplot_3) you'll see that neither give the desired result.
>
I see, I've change the `org-babel-gnuplot-quote-tsv-field' function so
that it will only wrap a value in double quotes if that value actually
needs these wraps (e.g., contains a quote or a space).
With this change your example 3 now works as expected (nice looking
plots by the way).
#+name: block_data_missing
| 1 | 1 | 2 |
| 1 | 2 | 5 |
| 1 | 3 | 10 |
| | | |
| 2 | 1 | 5 |
| 2 | 2 | 10 |
| 2 | 3 | 13 |
| | | |
| 3 | 1 | 10 |
| 3 | 2 | ? |
| 3 | 3 | 18 |
| | | |
| | | |
| 1 | 1 | 12 |
| 1 | 2 | 15 |
| 1 | 3 | 20 |
| | | |
| 2 | 1 | 15 |
| 2 | 2 | 18 |
| 2 | 3 | 23 |
| | | |
| 3 | 1 | ? |
| 3 | 2 | 23 |
| 3 | 3 | 28 |
#+name: gnuplot_3
#+begin_src gnuplot :var d=block_data_missing
set ticslevel 0
splot d index 0 u 1:2:3 w lp pt 6 ps 5, d index 1 u 1:2:3 w lp pt 6 ps 5
#+end_src
Are there any use cases which are still not addressed?
>
> If the block_data_missing table were exported exactly as it is except
> for the removal of the '|' characters and "set datafile missing '?'"
> were specified in the gnuplot script this would enable gnuplot to plot
> the red and green surfaces with the missing values. To see this try
> executing the last code block (gnuplot_4) which plots the data which
> is first "cleaned" by the shell command you suggested in a previous
> post. This would also remove the need to have the :missing header
> argument.
>
> Kind regards,
>
> Paul
>
--
Eric Schulte
http://cs.unm.edu/~eschulte
- Re: [O] using gnuplot's "splot" and "every" commands on org-mode table data, (continued)
- Re: [O] using gnuplot's "splot" and "every" commands on org-mode table data, Paul Stansell, 2013/05/07
- Re: [O] using gnuplot's "splot" and "every" commands on org-mode table data, Eric Schulte, 2013/05/07
- Re: [O] using gnuplot's "splot" and "every" commands on org-mode table data, Paul Stansell, 2013/05/07
- Re: [O] using gnuplot's "splot" and "every" commands on org-mode table data, Eric Schulte, 2013/05/08
- Re: [O] using gnuplot's "splot" and "every" commands on org-mode table data, Paul Stansell, 2013/05/08
- Re: [O] using gnuplot's "splot" and "every" commands on org-mode table data, Eric Schulte, 2013/05/13
- Re: [O] using gnuplot's "splot" and "every" commands on org-mode table data, Eric Schulte, 2013/05/17
- Re: [O] using gnuplot's "splot" and "every" commands on org-mode table data, Paul Stansell, 2013/05/17
- Re: [O] using gnuplot's "splot" and "every" commands on org-mode table data,
Eric Schulte <=
- Re: [O] using gnuplot's "splot" and "every" commands on org-mode table data, Paul Stansell, 2013/05/17
- Re: [O] using gnuplot's "splot" and "every" commands on org-mode table data, Paul Stansell, 2013/05/07
- Re: [O] using gnuplot's "splot" and "every" commands on org-mode table data, Eric Schulte, 2013/05/08
- Re: [O] using gnuplot's "splot" and "every" commands on org-mode table data, Paul Stansell, 2013/05/08
- Re: [O] using gnuplot's "splot" and "every" commands on org-mode table data, Achim Gratz, 2013/05/12
- Re: [O] using gnuplot's "splot" and "every" commands on org-mode table data, Eric Schulte, 2013/05/13
- Re: [O] using gnuplot's "splot" and "every" commands on org-mode table data, Achim Gratz, 2013/05/14
- Re: [O] using gnuplot's "splot" and "every" commands on org-mode table data, Achim Gratz, 2013/05/11