|
From: Jon <dev...@gm...> - 2014-03-21 20:36:44
|
Dear gnuplot users, I wonder whether I can get the coordinates of the four corners of the plot I am generating. I want to use this information to automatically put my labels to the intended location, so that I don't need to manually change them for different plots. Thanks, Sincerely, Jun |
|
From: BBands <bb...@gm...> - 2014-03-21 21:30:51
|
Would 'show xrange' and 'show yrange' help?
gnuplot can tell you a lot about itself. See 'help show'.
John
On Fri, Mar 21, 2014 at 1:36 PM, Jon <dev...@gm...> wrote:
> Dear gnuplot users,
>
> I wonder whether I can get the coordinates of the four corners of the plot
> I am generating. I want to use this information to automatically put my
> labels to the intended location, so that I don't need to manually change
> them for different plots.
|
|
From: Jon <dev...@gm...> - 2014-03-21 22:02:14
|
Thanks, it seems it does return some information concerning the range of the plot. But I wonder how I can possibly save them as parameters to be used for my purpose. It seems the plot will not know the range until it finishes plotting the data, but after the data is finished plotting the label, key etc have been put on the plot. On Fri, Mar 21, 2014 at 4:30 PM, BBands <bb...@gm...> wrote: > Would 'show xrange' and 'show yrange' help? > > gnuplot can tell you a lot about itself. See 'help show'. > > John > > On Fri, Mar 21, 2014 at 1:36 PM, Jon <dev...@gm...> wrote: > > Dear gnuplot users, > > > > I wonder whether I can get the coordinates of the four corners of the > plot > > I am generating. I want to use this information to automatically put my > > labels to the intended location, so that I don't need to manually change > > them for different plots. > > > ------------------------------------------------------------------------------ > Learn Graph Databases - Download FREE O'Reilly Book > "Graph Databases" is the definitive new guide to graph databases and their > applications. Written by three acclaimed leaders in the field, > this first edition is now available. Download your free book today! > http://p.sf.net/sfu/13534_NeoTech > _______________________________________________ > gnuplot-info mailing list > gnu...@li... > Membership management via: > https://lists.sourceforge.net/lists/listinfo/gnuplot-info > |
|
From: BBands <bb...@gm...> - 2014-03-21 22:11:06
|
Ah, I take your point. For that I wrote a simple preprocessor that
notes the high and low values of the series
i wish to plot and creates the appropriate range, label and plot
commands. Someone posted a solution here using a dummy plot a while
back, but I never investigated it.
Best,
John
On Fri, Mar 21, 2014 at 3:02 PM, Jon <dev...@gm...> wrote:
> Thanks, it seems it does return some information concerning the range of the
> plot. But I wonder how I can possibly save them as parameters to be used for
> my purpose. It seems the plot will not know the range until it finishes
> plotting the data, but after the data is finished plotting the label, key
> etc have been put on the plot.
|
|
From: Jon <dev...@gm...> - 2014-03-21 23:38:40
|
On Fri, Mar 21, 2014 at 6:04 PM, Hans-Bernhard Bröker <HBB...@t-... > wrote: > On 21.03.2014 21:36, Jon wrote: > > I wonder whether I can get the coordinates of the four corners of the plot >> I am generating. >> > > Not really, because these are fully dynamic. Their positions from one plot > have no tangible relation to the next one. > > > > I want to use this information to automatically put my > >> labels to the intended location, so that I don't need to manually change >> them for different plots. >> > > You're over-thinking this. I suggest you read "help set label" again. See > what it says about coordinates, then follow the hyperlink to "help > coordinates" > Thanks, maybe you are referring to absolute and relative coordinate, or something like that. I know that might be a way to address my concerns. Sincerely, Jon |
|
From: Thomas S. <t.s...@fz...> - 2014-03-22 10:32:33
|
BBands <bbands <at> gmail.com> writes: > > Ah, I take your point. For that I wrote a simple preprocessor that > notes the high and low values of the series > i wish to plot and creates the appropriate range, label and plot > commands. Someone posted a solution here using a dummy plot a while > back, but I never investigated it. > > Best, > > John > > On Fri, Mar 21, 2014 at 3:02 PM, Jon <devout1977 <at> gmail.com> wrote: > > Thanks, it seems it does return some information concerning the range of the > > plot. But I wonder how I can possibly save them as parameters to be used for > > my purpose. It seems the plot will not know the range until it finishes > > plotting the data, but after the data is finished plotting the label, key > > etc have been put on the plot. there is a bunch of gnuplot-defined variables GPVAL_* which contain the state of the recent plot. a simple solution would be to make a dummy plot, save the plot ranges, define the labels and then do the real plot: set terminal push set teminal dumb plot "filename" ... set xrange [GPVAL_X_MIN:GPVAL_X_MAX] set yrange [GPVAL_Y_MIN:GPVAL_Y_MAX] set label 1 sprintf("xmin: %f",GPVAL_X_MIN) at ... set label 2 sprintf("xmax: %f",GPVAL_X_MAX) at ... set terminal pop replot |
|
From: Jon <dev...@gm...> - 2014-03-22 16:18:49
|
Thanks, this really helps! On Sat, Mar 22, 2014 at 5:31 AM, Thomas Sefzick <t.s...@fz...>wrote: > BBands <bbands <at> gmail.com> writes: > > > > > Ah, I take your point. For that I wrote a simple preprocessor that > > notes the high and low values of the series > > i wish to plot and creates the appropriate range, label and plot > > commands. Someone posted a solution here using a dummy plot a while > > back, but I never investigated it. > > > > Best, > > > > John > > > > On Fri, Mar 21, 2014 at 3:02 PM, Jon <devout1977 <at> gmail.com> wrote: > > > Thanks, it seems it does return some information concerning the range > of the > > > plot. But I wonder how I can possibly save them as parameters to be > used for > > > my purpose. It seems the plot will not know the range until it finishes > > > plotting the data, but after the data is finished plotting the label, > key > > > etc have been put on the plot. > > > there is a bunch of gnuplot-defined variables > GPVAL_* > which contain the state of the recent plot. > > a simple solution would be to make a dummy plot, > save the plot ranges, define the labels and then > do the real plot: > > set terminal push > set teminal dumb > plot "filename" ... > > set xrange [GPVAL_X_MIN:GPVAL_X_MAX] > set yrange [GPVAL_Y_MIN:GPVAL_Y_MAX] > set label 1 sprintf("xmin: %f",GPVAL_X_MIN) at ... > set label 2 sprintf("xmax: %f",GPVAL_X_MAX) at ... > > set terminal pop > replot > > > > > > ------------------------------------------------------------------------------ > Learn Graph Databases - Download FREE O'Reilly Book > "Graph Databases" is the definitive new guide to graph databases and their > applications. Written by three acclaimed leaders in the field, > this first edition is now available. Download your free book today! > http://p.sf.net/sfu/13534_NeoTech > _______________________________________________ > gnuplot-info mailing list > gnu...@li... > Membership management via: > https://lists.sourceforge.net/lists/listinfo/gnuplot-info > |