|
From: Jon <dev...@gm...> - 2011-08-24 14:56:22
|
Thanks, Tatsuro, very interesting. I think it must work.
I did have figured out something using awk, but obviously it is much more
cumbersome
set macro
s1 = -10
s2 = 10
vv1=" ($1<"
vv2=") || ($1>"
vv3=") { print $1, $3 } ' fort.47"
ss = vv1.s1.vv2.s2.vv3
tt='plot "'.vv.ss.'"'.' u 1:2 w l'
@tt
Sincerely,
Jon
On Tue, Aug 23, 2011 at 11:53 PM, Tatsuro MATSUOKA
<tma...@ya...>wrote:
> Hello
>
> What you want to do may be done without awk.
>
> plot 'fort.47' using \
> ( ($1<s1) || ($1>s2) ? ($1) :1/0 ):($3)
>
> Note that I do not confirm the above.
> Regards
>
> Tatsuro
>
> --- On Wed, 2011/8/24, Jon wrote:
>
> > Dear All,
> >
> > I need to do something like this, use awk to filter out data within a
> > specific range whose limit is externally defined, say something like the
> > following,
> >
> > plot "< awk ' ($1<s1) || ($1>s2) { print $1, $3 } ' fort.47" u 1:2 w l
> >
> > here s1, s2 are variables defined in gnuplot to specify lower and upper
> > limit.
> >
> > The above does not work, as I think awk does not recognize s1 and s2
> defined
> > within gnuplot, how can I possibly fix it? Thanks,
> >
> > Sincerely,
> > Jon
> >
> ------------------------------------------------------------------------------
> > EMC VNX: the world's simplest storage, starting under $10K
> > The only unified storage solution that offers unified management
> > Up to 160% more powerful than alternatives and 25% more efficient.
> > Guaranteed. http://p.sf.net/sfu/emc-vnx-dev2dev
> > _______________________________________________
> > gnuplot-info mailing list
> > gnu...@li...
> > https://lists.sourceforge.net/lists/listinfo/gnuplot-info
> >
>
|