From mboxrd@z Thu Jan 1 00:00:00 1970 From: John Hendy Subject: Re: Gnuplot/babel issue with export to eps Date: Fri, 6 Jan 2012 11:02:16 -0600 Message-ID: References: Mime-Version: 1.0 Content-Type: multipart/alternative; boundary=0015175d021acc545104b5df0224 Return-path: Received: from eggs.gnu.org ([140.186.70.92]:43860) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1RjDBQ-0000te-9N for emacs-orgmode@gnu.org; Fri, 06 Jan 2012 12:02:26 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1RjDBJ-0002tu-D8 for emacs-orgmode@gnu.org; Fri, 06 Jan 2012 12:02:24 -0500 Received: from mail-ey0-f169.google.com ([209.85.215.169]:42969) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1RjDBJ-0002tn-4k for emacs-orgmode@gnu.org; Fri, 06 Jan 2012 12:02:17 -0500 Received: by eabm6 with SMTP id m6so1383765eab.0 for ; Fri, 06 Jan 2012 09:02:16 -0800 (PST) In-Reply-To: List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org Sender: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org To: Chris Malone Cc: emacs-orgmode --0015175d021acc545104b5df0224 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable On Fri, Jan 6, 2012 at 10:59 AM, John Hendy wrote: > On Thu, Jan 5, 2012 at 9:01 PM, John Hendy wrote: > >> On Thu, Jan 5, 2012 at 6:03 PM, Chris Malone w= rote: >> >>> Hi John, >>> >>> I'm not sure what Org mode is doing behind the scenes, but I suspect >>> something is getting muddled because you specify both the src block fil= e >>> header /and/ the output terminal in the gnu plot code. >>> >>> Perhaps a simpler solution - if you indeed want Postscript images - >>> would be to remove the =3D:file =E2=80=A6=3D header argument and specif= y the =3Dset >>> output=3D within the gnuplot script itself? That should still generate= the >>> .eps file. >>> >>> >> I may give this a try at work tomorrow... just tried the same file on my >> Mac at home (running the same linux setup) and it's working, though I st= ill >> get a filename.eps and a filename-eps-converted-to.pdf output. It's just >> that the .eps on this computer is valid and viewable. >> >> I'll have to dig into this some more; perhaps comparing org versions and >> .emacs config files. >> >> I'm pulling from the org git repo and doing a make now on this computer >> as we speak. If it still works, I'll do the same at work tomorrow and se= e >> if that helps. >> >> > Fresh org pull, same file... no viable output. The =3Dset output "test.ep= s"=3D > command with no :file header does not work. I get "code block produced no > output" in the minibuffer. > > Here's some things of interest... > -- Removing =3Dset terminal...=3D and exporting via =3D:file test.png=3D = works > -- Using =3Dset terminal postscript=3D and =3D:file test.ps=3D works > -- Using =3Dset terminal postscript eps enhanced=3D and =3D:file test.eps= =3D does > *not* work > > What package provides the eps ability? Perhaps I removed something from m= y > system that I didn't intend to! > > Any suggestions on how to see what's going on? > > Shoot. It's geeqie. On a hunch, I opened the eps in gimp and it views fine. Something's wrong with my image viewer... False alarm; org/babel/gnuplot are working fine. John > > Thanks, > John > > >> >> Thanks for the input, >> John >> >> >> >>> Chris >>> >>> On Jan 5, 2012, at 3:54 PM, John Hendy wrote: >>> >>> I have the following gnuplot/babel block and for some reason the >>> resultant .eps file comes up broken but a corresponding version of it g= ets >>> converted to pdf somehow... what's going on? I stole an example just to >>> check and make sure it wasn't my gnuplot code: >>> http://t16web.lanl.gov/Kawano/gnuplot/intro/plotfunc-e.html >>> >>> ----- >>> #+begin_src gnuplot :file export.eps :exports results >>> reset >>> >>> set terminal postscript eps color enhanced 20 >>> >>> a=3D0.25 >>> b=3D0.02 >>> c=3D0.05 >>> d=3D0.1 >>> f(x)=3Dc/((x-a)*(x-a)+b)+d/sqrt(x) >>> set xrange [0:1] >>> set yrange [0:4] >>> plot f(x) >>> >>> #+end_src >>> ----- >>> >>> I get a file export.eps which is broken and unreadable by geeqie. I get >>> a corresponding file called export-eps-converted-to.pdf that opens fine= and >>> looks like it should. >>> >>> What am I doing incorrectly? >>> >>> >>> Thanks, >>> John >>> >>> >>> >>> -----------------------------------------------------------------------= -- >>> Chris Malone (malone@ucolick.org) >>> >>> Dept. of Astronomy and Astrophysics >>> UC Santa Cruz >>> 1156 High Street >>> Santa Cruz, CA 95064-1077 >>> >>> phone: 831-459-3809 >>> -----------------------------------------------------------------------= -- >>> >>> >> > --0015175d021acc545104b5df0224 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
On Fri, Jan 6, 2012 at 10:59 AM, John Hendy <jw.hendy@gmail.com<= /a>> wrote:
On Thu, Jan 5, 2012 at 9:01 PM= , John Hendy <jw.hendy@gmail.com> wrote:
On Thu, Jan 5, 2012 at 6:03 PM, Chris Malon= e <chris.m.malone@gmail.com> wrote:
Hi John,

I'm not= sure what Org mode is doing behind the scenes, but I suspect something is = getting muddled because you specify both the src block file header /and/ th= e output terminal in the gnu plot code.

Perhaps a simpler solution - if you indeed want Postscr= ipt images - would be to remove the =3D:file =E2=80=A6=3D header argument a= nd specify the =3Dset output=3D within the gnuplot script itself? =C2=A0Tha= t should still generate the .eps file.


I may give this= a try at work tomorrow... just tried the same file on my Mac at home (runn= ing the same linux setup) and it's working, though I still get a filena= me.eps and a filename-eps-converted-to.pdf output. It's just that the .= eps on this computer is valid and viewable.

I'll have to dig into this some more; perhaps compa= ring org versions and .emacs config files.

I'm= pulling from the org git repo and doing a make now on this computer as we = speak. If it still works, I'll do the same at work tomorrow and see if = that helps.


Fresh org pull,= same file... no viable output. The =3Dset output "test.eps"=3D c= ommand with no :file header does not work. I get "code block produced = no output" in the minibuffer.

Here's some things of interest...
-- Remo= ving =3Dset terminal...=3D and exporting via =3D:file test.png=3D works
-- Using =3Dset terminal postscript=3D and =3D:file test.ps=3D works
-- Using =3Dset terminal postscript eps enhanced=3D and =3D:file test.= eps=3D does *not* work

What package provides the e= ps ability? Perhaps I removed something from my system that I didn't in= tend to!

Any suggestions on how to see what's going on?


Shoot. It's geeq= ie. On a hunch, I opened the eps in gimp and it views fine. Something's= wrong with my image viewer...

False alarm; org/babel/gnuplot are working fine.
<= div>

John
=C2=A0

Thanks,
John
=C2=A0

Thanks for the in= put,
John

=C2=A0
Chris

On Jan 5, 2012, at = 3:54 PM, John Hendy wrote:

I have the fo= llowing gnuplot/babel block and for some reason the resultant .eps file com= es up broken but a corresponding version of it gets converted to pdf someho= w... what's going on? I stole an example just to check and make sure it= wasn't my gnuplot code:=C2=A0http://t16web.lanl.gov/Kaw= ano/gnuplot/intro/plotfunc-e.html

-----
#+begin_src gnuplot :file export.eps :e= xports results
reset

set terminal postsc= ript eps color enhanced 20

a=3D0.25
=C2= =A0b=3D0.02
=C2=A0c=3D0.05
=C2=A0d=3D0.1
=C2=A0f(x)=3Dc/((x-a)= *(x-a)+b)+d/sqrt(x)
=C2=A0set xrange [0:1]
=C2=A0set yr= ange [0:4]
=C2=A0plot f(x)

#+end_src
-----

I get a file export.eps which is broken and unreadable by geeqie= . I get a corresponding file called export-eps-converted-to.pdf that opens = fine and looks like it should.

What am I doing inc= orrectly?


Thanks,
John

-----------------------------------------------------------------= --------
Chris Malone (malone@ucolick.org)

Dept. = of Astronomy and Astrophysics
UC Santa Cruz
1156 High Street
Santa Cruz, CA 9506= 4-1077

-------= ------------------------------------------------------------------




--0015175d021acc545104b5df0224--