emacs-orgmode
[Top][All Lists]
Advanced

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

Re: [Orgmode] org-babel and gnuplot


From: John Hendy
Subject: Re: [Orgmode] org-babel and gnuplot
Date: Tue, 7 Sep 2010 20:54:20 -0500

Hi Nick,

Maybe two things off hand (booted into OS X right now where I can't try your code..)

1) try using straight gnuplot without going through org to verify your commands. This helps make sure that the syntax isn't producing errors. Another way to check this out sometimes is to C-c C-c on the code block, run the code, and then C-x b to the *gnuplot buffer to view any error messages. Those might prove helpful.

2) try changing your plot line to: plot data using 1:2:3 notitle

I think I ran into an issue using "$data" even though it's the gnuplot syntax. I found org examples on the mailing list where just "data" was used instead (no quotes) and that worked.


John

P.S. Are you trying to make a 3D graph? plot using 1:2:3 will yield a 3D graph and you didn't mention a z-axis label so I'm wondering if that's really what you want? You may want to split this into two graphs to have date vs. time and date vs. distance? Or date vs. distance/time (speed)?

P.P.S Or perhaps judging by the boxwidth option you want the width of the bars in the graph to represent the miles run? In that case you want 'plot data using 1:2:3 with boxes notitle' I think.



On Tue, Sep 7, 2010 at 8:29 PM, Nick Parker <address@hidden> wrote:
Hello,

I am attempting to generate a simple chart from gnuplot using the source of an org-table.  When I execute the gnuplot src block I get the message "Source block produced no output".  Does anyone have any suggestions as to what might be the cause?  I have included a sample of what I am trying to run:

#+tblname: sessions
| Date       |  Time | Distance |
|------------+-------+----------|
| 09/02/2010 | 15:13 |      2.5 |
| 09/01/2010 | 14:00 |      2.4 |

#+begin_src gnuplot :var data="">
  :file org-running.png :exports both
  set title "Running Stats"
  set auto x
  set style data histogram
  set style fill solid border -1
  set boxwidth .9
  set xlabel "Date"
  set ylabel "Time"
  plot "$data" using 1:2:3 notitle
#+end_src


_______________________________________________
Emacs-orgmode mailing list
Please use `Reply All' to send replies to the list.
address@hidden
http://lists.gnu.org/mailman/listinfo/emacs-orgmode



reply via email to

[Prev in Thread] Current Thread [Next in Thread]