Rocksolid Light

Welcome to novaBBS (click a section below)

mail  files  register  newsreader  groups  login

Message-ID:  

Linux is obsolete -- Andrew Tanenbaum


devel / comp.graphics.apps.gnuplot / Re: How to produce screenplot and pslatex-plot with one batch file

SubjectAuthor
* How to produce screenplot and pslatex-plot with one batch filehugocoolens@gmail.com
`* Re: How to produce screenplot and pslatex-plot with one batch fileGavin Buxton
 `* Re: How to produce screenplot and pslatex-plot with one batch filehugocoolens@gmail.com
  `* Re: How to produce screenplot and pslatex-plot with one batch fileGavin Buxton
   `- Re: How to produce screenplot and pslatex-plot with one batch filehugocoolens@gmail.com

1
How to produce screenplot and pslatex-plot with one batch file

<e95b190e-372c-43c2-832e-4ae317cbecddn@googlegroups.com>

 copy mid

https://www.novabbs.com/devel/article-flat.php?id=40&group=comp.graphics.apps.gnuplot#40

 copy link   Newsgroups: comp.graphics.apps.gnuplot
X-Received: by 2002:a05:622a:11c3:: with SMTP id n3mr28520173qtk.211.1625754646539;
Thu, 08 Jul 2021 07:30:46 -0700 (PDT)
X-Received: by 2002:a25:8a:: with SMTP id 132mr1523246yba.67.1625754646258;
Thu, 08 Jul 2021 07:30:46 -0700 (PDT)
Path: i2pn2.org!i2pn.org!weretis.net!feeder6.news.weretis.net!4.us.feeder.erje.net!2.eu.feeder.erje.net!feeder.erje.net!proxad.net!feeder1-2.proxad.net!209.85.160.216.MISMATCH!news-out.google.com!nntp.google.com!postnews.google.com!google-groups.googlegroups.com!not-for-mail
Newsgroups: comp.graphics.apps.gnuplot
Date: Thu, 8 Jul 2021 07:30:46 -0700 (PDT)
Injection-Info: google-groups.googlegroups.com; posting-host=2a02:a03f:eb28:9f00:55c5:cf8f:4da2:71e8;
posting-account=6f4zEAoAAABcPGvJdTxtF_Mhoal-gK1d
NNTP-Posting-Host: 2a02:a03f:eb28:9f00:55c5:cf8f:4da2:71e8
User-Agent: G2/1.0
MIME-Version: 1.0
Message-ID: <e95b190e-372c-43c2-832e-4ae317cbecddn@googlegroups.com>
Subject: How to produce screenplot and pslatex-plot with one batch file
From: hugocool...@gmail.com (hugocoolens@gmail.com)
Injection-Date: Thu, 08 Jul 2021 14:30:46 +0000
Content-Type: text/plain; charset="UTF-8"
 by: hugocoolens@gmail.co - Thu, 8 Jul 2021 14:30 UTC

I currently use Gnuplot as follows:
I write a batch-file myfile.gp with the following commands in comment
#set terminal pslatex size 25cm,17cm monochrome
#set output "fileforlatex.tex"

I first run the batch file to see if plot is OK on screen, like this
gnuplot <myfile.gp --persist
If the result seems OK, I edit the original batch file and remove the #
such that I have:
set terminal pslatex size 25cm,17cm monochrome
set output "fileforlatex.tex"

The I rerun Gnuplot:
gnuplot <myfile.gp

I wonder whether it is possible to see the result on screen _and_ produce the fileforlatex.tex at the same time?

Here is a trivial example batch file: myfile.gp:
#set terminal pslatex size 25cm,17cm monochrome
#set output "fileforlatex.tex"
plot sin(x)
set output

kind regards,
Hugo

Re: How to produce screenplot and pslatex-plot with one batch file

<cff8b4a1-6be9-4fd0-bb7c-89e31c11371en@googlegroups.com>

 copy mid

https://www.novabbs.com/devel/article-flat.php?id=41&group=comp.graphics.apps.gnuplot#41

 copy link   Newsgroups: comp.graphics.apps.gnuplot
X-Received: by 2002:ac8:4741:: with SMTP id k1mr34363956qtp.374.1625843919978;
Fri, 09 Jul 2021 08:18:39 -0700 (PDT)
X-Received: by 2002:a25:d1c1:: with SMTP id i184mr47514716ybg.193.1625843919678;
Fri, 09 Jul 2021 08:18:39 -0700 (PDT)
Path: i2pn2.org!i2pn.org!weretis.net!feeder8.news.weretis.net!proxad.net!feeder1-2.proxad.net!209.85.160.216.MISMATCH!news-out.google.com!nntp.google.com!postnews.google.com!google-groups.googlegroups.com!not-for-mail
Newsgroups: comp.graphics.apps.gnuplot
Date: Fri, 9 Jul 2021 08:18:39 -0700 (PDT)
In-Reply-To: <e95b190e-372c-43c2-832e-4ae317cbecddn@googlegroups.com>
Injection-Info: google-groups.googlegroups.com; posting-host=2601:547:300:da50:14b4:927:7870:4ba9;
posting-account=yC8mVwkAAADuRBqBIdPVfec50l5EMdYn
NNTP-Posting-Host: 2601:547:300:da50:14b4:927:7870:4ba9
References: <e95b190e-372c-43c2-832e-4ae317cbecddn@googlegroups.com>
User-Agent: G2/1.0
MIME-Version: 1.0
Message-ID: <cff8b4a1-6be9-4fd0-bb7c-89e31c11371en@googlegroups.com>
Subject: Re: How to produce screenplot and pslatex-plot with one batch file
From: gavinbux...@gmail.com (Gavin Buxton)
Injection-Date: Fri, 09 Jul 2021 15:18:39 +0000
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
 by: Gavin Buxton - Fri, 9 Jul 2021 15:18 UTC

Hi

I might be misunderstanding your question, but it seems like you want to see the output of your plot when the terminal is tex. I usually use ps or png files and then embed them in latex afterwards, so I would check it using something like:

set term post
set output 'temp.ps'
plot sin(x)
set output
!gv temp.ps

where the last command would open the file using ghostview (the exclamation mark just allows you to run external programs from gnuplot commandline). I don't use tex file directly, but I imagine to view the tex file you would need an external viewer of some kind?

Best

Gavin

Re: How to produce screenplot and pslatex-plot with one batch file

<1cf904fc-5f50-43c1-880a-d8b6a379d4cdn@googlegroups.com>

 copy mid

https://www.novabbs.com/devel/article-flat.php?id=42&group=comp.graphics.apps.gnuplot#42

 copy link   Newsgroups: comp.graphics.apps.gnuplot
X-Received: by 2002:a37:681:: with SMTP id 123mr145221qkg.453.1625909024161;
Sat, 10 Jul 2021 02:23:44 -0700 (PDT)
X-Received: by 2002:a25:7ec4:: with SMTP id z187mr51940967ybc.136.1625909023860;
Sat, 10 Jul 2021 02:23:43 -0700 (PDT)
Path: i2pn2.org!i2pn.org!weretis.net!feeder8.news.weretis.net!proxad.net!feeder1-2.proxad.net!209.85.160.216.MISMATCH!news-out.google.com!nntp.google.com!postnews.google.com!google-groups.googlegroups.com!not-for-mail
Newsgroups: comp.graphics.apps.gnuplot
Date: Sat, 10 Jul 2021 02:23:43 -0700 (PDT)
In-Reply-To: <cff8b4a1-6be9-4fd0-bb7c-89e31c11371en@googlegroups.com>
Injection-Info: google-groups.googlegroups.com; posting-host=2a02:a03f:eb28:9f00:55c5:cf8f:4da2:71e8;
posting-account=6f4zEAoAAABcPGvJdTxtF_Mhoal-gK1d
NNTP-Posting-Host: 2a02:a03f:eb28:9f00:55c5:cf8f:4da2:71e8
References: <e95b190e-372c-43c2-832e-4ae317cbecddn@googlegroups.com> <cff8b4a1-6be9-4fd0-bb7c-89e31c11371en@googlegroups.com>
User-Agent: G2/1.0
MIME-Version: 1.0
Message-ID: <1cf904fc-5f50-43c1-880a-d8b6a379d4cdn@googlegroups.com>
Subject: Re: How to produce screenplot and pslatex-plot with one batch file
From: hugocool...@gmail.com (hugocoolens@gmail.com)
Injection-Date: Sat, 10 Jul 2021 09:23:44 +0000
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
 by: hugocoolens@gmail.co - Sat, 10 Jul 2021 09:23 UTC

On Friday, July 9, 2021 at 5:18:40 PM UTC+2, Gavin Buxton wrote:
> Hi
>
> I might be misunderstanding your question, but it seems like you want to see the output of your plot when the terminal is tex. I usually use ps or png files and then embed them in latex afterwards, so I would check it using something like:
>
> set term post
> set output 'temp.ps'
> plot sin(x)
> set output
> !gv temp.ps
>
> where the last command would open the file using ghostview (the exclamation mark just allows you to run external programs from gnuplot commandline). I don't use tex file directly, but I imagine to view the tex file you would need an external viewer of some kind?
>
> Best
>
>
> Gavin
Dear Gavin,
Thanks for your answer but this is not what I want. I really want pslatex output as that gives nicer graphs than plain postscript. What I want is a default screen plot _and_ a pslatex-file all in one script.
Maybe someone else has a suggestion?

kind regards,
Hugo

Re: How to produce screenplot and pslatex-plot with one batch file

<44ade153-21e2-4340-a4cf-8b66e5eb83f8n@googlegroups.com>

 copy mid

https://www.novabbs.com/devel/article-flat.php?id=43&group=comp.graphics.apps.gnuplot#43

 copy link   Newsgroups: comp.graphics.apps.gnuplot
X-Received: by 2002:a37:6203:: with SMTP id w3mr31670819qkb.81.1625929646030; Sat, 10 Jul 2021 08:07:26 -0700 (PDT)
X-Received: by 2002:a5b:8c6:: with SMTP id w6mr46557890ybq.258.1625929645769; Sat, 10 Jul 2021 08:07:25 -0700 (PDT)
Path: i2pn2.org!i2pn.org!aioe.org!news.uzoreto.com!tr1.eu1.usenetexpress.com!feeder.usenetexpress.com!tr2.iad1.usenetexpress.com!border1.nntp.dca1.giganews.com!nntp.giganews.com!news-out.google.com!nntp.google.com!postnews.google.com!google-groups.googlegroups.com!not-for-mail
Newsgroups: comp.graphics.apps.gnuplot
Date: Sat, 10 Jul 2021 08:07:25 -0700 (PDT)
In-Reply-To: <1cf904fc-5f50-43c1-880a-d8b6a379d4cdn@googlegroups.com>
Injection-Info: google-groups.googlegroups.com; posting-host=2601:547:300:da50:f9ed:d8a:55aa:b4f9; posting-account=yC8mVwkAAADuRBqBIdPVfec50l5EMdYn
NNTP-Posting-Host: 2601:547:300:da50:f9ed:d8a:55aa:b4f9
References: <e95b190e-372c-43c2-832e-4ae317cbecddn@googlegroups.com> <cff8b4a1-6be9-4fd0-bb7c-89e31c11371en@googlegroups.com> <1cf904fc-5f50-43c1-880a-d8b6a379d4cdn@googlegroups.com>
User-Agent: G2/1.0
MIME-Version: 1.0
Message-ID: <44ade153-21e2-4340-a4cf-8b66e5eb83f8n@googlegroups.com>
Subject: Re: How to produce screenplot and pslatex-plot with one batch file
From: gavinbux...@gmail.com (Gavin Buxton)
Injection-Date: Sat, 10 Jul 2021 15:07:26 +0000
Content-Type: text/plain; charset="UTF-8"
Lines: 9
 by: Gavin Buxton - Sat, 10 Jul 2021 15:07 UTC

Ah, I think I see now. You could

set terminal pslatex size 25cm,17cm monochrome
set output "fileforlatex.tex"
plot sin(x)
set output
set term x11
rep

and just plot it again to the screen, but it might not look the same in a different terminal.

Re: How to produce screenplot and pslatex-plot with one batch file

<ce48011d-8e32-4641-bb57-d16a5c24d372n@googlegroups.com>

 copy mid

https://www.novabbs.com/devel/article-flat.php?id=44&group=comp.graphics.apps.gnuplot#44

 copy link   Newsgroups: comp.graphics.apps.gnuplot
X-Received: by 2002:a37:ad0d:: with SMTP id f13mr3686316qkm.453.1626177234489;
Tue, 13 Jul 2021 04:53:54 -0700 (PDT)
X-Received: by 2002:a25:3482:: with SMTP id b124mr5171813yba.297.1626177234249;
Tue, 13 Jul 2021 04:53:54 -0700 (PDT)
Path: i2pn2.org!i2pn.org!weretis.net!feeder8.news.weretis.net!proxad.net!feeder1-2.proxad.net!209.85.160.216.MISMATCH!news-out.google.com!nntp.google.com!postnews.google.com!google-groups.googlegroups.com!not-for-mail
Newsgroups: comp.graphics.apps.gnuplot
Date: Tue, 13 Jul 2021 04:53:54 -0700 (PDT)
In-Reply-To: <44ade153-21e2-4340-a4cf-8b66e5eb83f8n@googlegroups.com>
Injection-Info: google-groups.googlegroups.com; posting-host=2a02:a03f:eb28:9f00:55c5:cf8f:4da2:71e8;
posting-account=6f4zEAoAAABcPGvJdTxtF_Mhoal-gK1d
NNTP-Posting-Host: 2a02:a03f:eb28:9f00:55c5:cf8f:4da2:71e8
References: <e95b190e-372c-43c2-832e-4ae317cbecddn@googlegroups.com>
<cff8b4a1-6be9-4fd0-bb7c-89e31c11371en@googlegroups.com> <1cf904fc-5f50-43c1-880a-d8b6a379d4cdn@googlegroups.com>
<44ade153-21e2-4340-a4cf-8b66e5eb83f8n@googlegroups.com>
User-Agent: G2/1.0
MIME-Version: 1.0
Message-ID: <ce48011d-8e32-4641-bb57-d16a5c24d372n@googlegroups.com>
Subject: Re: How to produce screenplot and pslatex-plot with one batch file
From: hugocool...@gmail.com (hugocoolens@gmail.com)
Injection-Date: Tue, 13 Jul 2021 11:53:54 +0000
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
 by: hugocoolens@gmail.co - Tue, 13 Jul 2021 11:53 UTC

On Saturday, July 10, 2021 at 5:07:26 PM UTC+2, Gavin Buxton wrote:
> Ah, I think I see now. You could
> set terminal pslatex size 25cm,17cm monochrome
> set output "fileforlatex.tex"
> plot sin(x)
> set output
> set term x11
> rep
>
> and just plot it again to the screen, but it might not look the same in a different terminal.
Dear Gavin,
This is exactly what I needed. It makes my workflow a lot more efficient because when I see the plot looks OK on the screen I can now immediately start LaTeX, otherwise I always had to put those two lines in comment and rerun Gnuplot an extra time to produce the LaTeX picture.
Thanks a lot and kind regards,
Hugo

1
server_pubkey.txt

rocksolid light 0.9.7
clearnet tor