You can subscribe to this list here.
| 2003 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
(2) |
Nov
(2) |
Dec
|
|---|---|---|---|---|---|---|---|---|---|---|---|---|
| 2004 |
Jan
(3) |
Feb
(1) |
Mar
(2) |
Apr
(22) |
May
(52) |
Jun
(43) |
Jul
(36) |
Aug
(59) |
Sep
(37) |
Oct
(55) |
Nov
(39) |
Dec
(36) |
| 2005 |
Jan
(64) |
Feb
(40) |
Mar
(62) |
Apr
(58) |
May
(256) |
Jun
(77) |
Jul
(80) |
Aug
(39) |
Sep
(56) |
Oct
(36) |
Nov
(113) |
Dec
(68) |
| 2006 |
Jan
(43) |
Feb
(64) |
Mar
(69) |
Apr
(60) |
May
(71) |
Jun
(53) |
Jul
(63) |
Aug
(63) |
Sep
(76) |
Oct
(85) |
Nov
(82) |
Dec
(73) |
| 2007 |
Jan
(75) |
Feb
(82) |
Mar
(84) |
Apr
(104) |
May
(67) |
Jun
(101) |
Jul
(107) |
Aug
(138) |
Sep
(128) |
Oct
(106) |
Nov
(112) |
Dec
(112) |
| 2008 |
Jan
(94) |
Feb
(87) |
Mar
(146) |
Apr
(169) |
May
(75) |
Jun
(26) |
Jul
(26) |
Aug
(7) |
Sep
(18) |
Oct
(53) |
Nov
(42) |
Dec
(19) |
| 2009 |
Jan
(43) |
Feb
(39) |
Mar
(18) |
Apr
(45) |
May
(66) |
Jun
(87) |
Jul
(56) |
Aug
(41) |
Sep
(56) |
Oct
(139) |
Nov
(98) |
Dec
(88) |
| 2010 |
Jan
(81) |
Feb
(79) |
Mar
(83) |
Apr
(97) |
May
(124) |
Jun
(84) |
Jul
(53) |
Aug
(85) |
Sep
(89) |
Oct
(50) |
Nov
(98) |
Dec
(78) |
| 2011 |
Jan
(97) |
Feb
(74) |
Mar
(68) |
Apr
(54) |
May
(63) |
Jun
(59) |
Jul
(65) |
Aug
(58) |
Sep
(37) |
Oct
(40) |
Nov
(59) |
Dec
(35) |
| 2012 |
Jan
(16) |
Feb
(56) |
Mar
(63) |
Apr
(25) |
May
(48) |
Jun
(58) |
Jul
(20) |
Aug
(13) |
Sep
(43) |
Oct
(35) |
Nov
(20) |
Dec
(17) |
| 2013 |
Jan
(22) |
Feb
(11) |
Mar
(51) |
Apr
(34) |
May
(57) |
Jun
(27) |
Jul
(70) |
Aug
(30) |
Sep
(38) |
Oct
(53) |
Nov
(40) |
Dec
(25) |
| 2014 |
Jan
(26) |
Feb
(35) |
Mar
(60) |
Apr
(12) |
May
(17) |
Jun
(15) |
Jul
(9) |
Aug
(18) |
Sep
(46) |
Oct
(18) |
Nov
(19) |
Dec
(15) |
| 2015 |
Jan
(17) |
Feb
(28) |
Mar
(21) |
Apr
(54) |
May
(36) |
Jun
(8) |
Jul
(30) |
Aug
(13) |
Sep
(3) |
Oct
(28) |
Nov
(3) |
Dec
(3) |
| 2016 |
Jan
(11) |
Feb
(9) |
Mar
(29) |
Apr
(10) |
May
(8) |
Jun
(5) |
Jul
(50) |
Aug
(57) |
Sep
(13) |
Oct
(5) |
Nov
(17) |
Dec
(11) |
| 2017 |
Jan
(3) |
Feb
(23) |
Mar
(16) |
Apr
(7) |
May
(15) |
Jun
(12) |
Jul
(48) |
Aug
(15) |
Sep
(3) |
Oct
(20) |
Nov
(28) |
Dec
(21) |
| 2018 |
Jan
(13) |
Feb
(21) |
Mar
(21) |
Apr
(7) |
May
(3) |
Jun
(7) |
Jul
(27) |
Aug
(38) |
Sep
(4) |
Oct
(30) |
Nov
(22) |
Dec
|
| 2019 |
Jan
(5) |
Feb
(16) |
Mar
(1) |
Apr
(9) |
May
(7) |
Jun
(20) |
Jul
(13) |
Aug
(3) |
Sep
(2) |
Oct
(2) |
Nov
(2) |
Dec
(4) |
| 2020 |
Jan
(6) |
Feb
(11) |
Mar
(1) |
Apr
(18) |
May
(4) |
Jun
(5) |
Jul
(12) |
Aug
(1) |
Sep
(3) |
Oct
(7) |
Nov
(1) |
Dec
(17) |
| 2021 |
Jan
(1) |
Feb
(11) |
Mar
(16) |
Apr
(6) |
May
(5) |
Jun
(1) |
Jul
(1) |
Aug
(2) |
Sep
(8) |
Oct
(10) |
Nov
(4) |
Dec
(4) |
| 2022 |
Jan
(9) |
Feb
(35) |
Mar
(4) |
Apr
|
May
(3) |
Jun
(49) |
Jul
(11) |
Aug
|
Sep
(5) |
Oct
(2) |
Nov
(16) |
Dec
(13) |
| 2023 |
Jan
|
Feb
(8) |
Mar
(3) |
Apr
|
May
(8) |
Jun
|
Jul
(5) |
Aug
|
Sep
|
Oct
(2) |
Nov
|
Dec
(2) |
| 2024 |
Jan
(6) |
Feb
(9) |
Mar
|
Apr
(26) |
May
(24) |
Jun
|
Jul
(4) |
Aug
(2) |
Sep
(1) |
Oct
(10) |
Nov
(9) |
Dec
|
| 2025 |
Jan
|
Feb
(22) |
Mar
|
Apr
(1) |
May
|
Jun
|
Jul
|
Aug
|
Sep
(1) |
Oct
(1) |
Nov
|
Dec
(4) |
| 2026 |
Jan
|
Feb
(24) |
Mar
(20) |
Apr
(18) |
May
(2) |
Jun
(2) |
Jul
(2) |
Aug
(3) |
Sep
(6) |
Oct
(3) |
Nov
(2) |
Dec
|
|
From: theozh <th...@gm...> - 2016-08-08 07:22:32
|
sometimes it's helpful to generate some test or dummy data. I hoped that I can create some test data (columns and/or matrices) with "set table". Is there a way to generate N-column or M x N-matrix random data? e.g. like 0.10 0.45 0.91 0.50 0.55 0.57 0.19 0.74 0.28 0.06 0.85 0.09 0.27 0.27 0.80 0.08 0.31 0.08 0.66 0.43 0.77 0.80 1.00 0.14 0.50 For example, I expected the following code to produce a 5x5 matrix of random data. reset set samples 5 set table "Test.dat" plot rand(0):rand(0):rand(0):rand(0):rand(0) with table # or maybe # plot rand(0),rand(0),rand(0),rand(0),rand(0) with table # or "splot ... something" unset table But this seems not to work like this. I also tried "set parametric" like in the "random-demos"... While fiddling around I found that the following code would create such a 5x5 matrix: ####### generate 5x5 matrix of random numbers reset $Data <<EOD 1 1 2 1 3 1 4 1 5 1 EOD set table "Test.dat" plot $Data using \ ($2*rand(0)):($2*rand(0)):($2*rand(0)):($2*rand(0)):($2*rand(0)) \ with table unset table ####### EOF Two questions: 1) How would I do this for a 1000x1000 matrix? Repeating ($2*rand(0)) a thousand times...??? 2) Ideally, I also wanted the data to be separated by TAB instead of space. So, if I additionally set in the above working code set datafile separator "\t" I get the error message: "...x range is invalid" Any ideas? |
|
From: theozh <th...@gm...> - 2016-08-08 06:02:42
|
thanks, Joseph, for that hint. Actually, my hope was to realize this in gnuplot itself and to avoid an additional program and installation. Nevertheless, I will have a look at it... |
|
From: theozh <th...@gm...> - 2016-08-08 05:37:14
|
Make sure you're using the newest gnuplot version. If you read "help size" carefully you will see that size of the plot is in relative units to the size of the canvas. This apparently was different in older gnuplot versions and/or terminals. reset set terminal pdfcairo size 17in,11in set output "test.pdf" # calculate the ratio of 8in to 17in and 10in to 11in # need to add . to force floating point division set size 8/17.,10/11. plot x**2 unset output |
|
From: mikeincousa <mik...@gm...> - 2016-08-06 23:44:54
|
It all sounds so simple and easy, so I must be missing something somewhere.
What I want to do is place a full scale 8 x 10 inch plot on tabloid sized
paper.
1
gnuplot> reset
gnuplot> unset autoscale
gnuplot> set terminal pdfcairo size 17in,11in #landscape
Terminal type set to 'pdfcairo'
Options are ' transparent enhanced fontscale 0.5 size 17.00in, 11.00in '
gnuplot> set output "test.pdf"
gnuplot> set size 8in,10in
^
unexpected or unrecognized token
gnuplot> plot x**2
gnuplot> unset output
2.
set size ratio 8in,10in
#returns a 10 x 10 square
3.
set size nosquare 8in,10in
^
unexpected or unrecognized token
4. and on and on....
--
View this message in context: http://gnuplot.10905.n7.nabble.com/Canvas-plot-size-confusion-tp20301.html
Sent from the Gnuplot - User mailing list archive at Nabble.com.
|
|
From: theozh <th...@gm...> - 2016-08-06 14:31:59
|
if the arrow length is reduced to small values towards zero the arrow
head is also changing. Actually, I would have expected that the arrow
heads stay always the same. But they are not as you can easily check
with the following code.
####### Test arrows
reset
set xrange[0:20]
set yrange[0:3]
do for [i=1:20] {
set arrow 3*i from i,0 to i,i/50.
set arrow 3*i+1 from i,1 to i,1+i/50. head size 1,15,45 filled
set arrow 3*i+2 from i,2 length i/10. angle 90 head size 1,15,45 filled
}
plot 0 notitle
######
I guess that's not want you wanted for your arrow heads?!
So, I thought arrow heads can also be created by polygons.
set object 1 polygon from x1,y1 to x2,y2 to ... to x1,y1
The following code is a "workaround" just for fun...
It looks (and maybe is) complicated but basically it's just a few
coordinate transformations.
The necessary input parameters for the arrow heads are the following:
ax = 0 # x-value in x1-axis coordinates arrow head points to
ay = 0 # y-value in y1-axis coordinates arrow head points to
AA = 45 # ArrowAngle
HL = 0.05 # HeadLength in fractions of screen width
HA = 15 # HeadAngle
BA = 45 # BackAngle
There might be certainly a more elegant way to do it.
Hope there is no bug in it, but it worked for me on a wxt terminal.
The size and shape of the arrow heads do do not depend on the graph
scale but just on the screen.
####### Test_Arrow2.plt
####### Arrow heads without shaft realized with polygons
reset
set xrange[-10:10]
set yrange[-10:10]
set size square
set angle degrees
# needs to plot something to update the range and GPVAL_ values?!
plot 0 notitle
# setting of arrow parameters
ax = 0 # x-value in x1-axis coordinates arrow head points to
ay = 0 # y-value in y1-axis coordinates arrow head points to
AA = 45 # ArrowAngle
HL = 0.05 # HeadLength in fraction of screen width
HA = 15 # HeadAngle
BA = 45 # BackAngle
# define a few coordinate functions
aFracX(xx) = (xx - GPVAL_X_MIN) / ((GPVAL_X_MAX - GPVAL_X_MIN))
aFracY(yy) = (yy - GPVAL_Y_MIN) / ((GPVAL_Y_MAX - GPVAL_Y_MIN))
aFracScrX(xx)= (GPVAL_TERM_XMIN + aFracX(xx)\
*(GPVAL_TERM_XMAX - GPVAL_TERM_XMIN))/GPVAL_TERM_XSIZE
aFracScrY(yy) = (GPVAL_TERM_YMIN + aFracY(yy)\
*(GPVAL_TERM_YMAX - GPVAL_TERM_YMIN))/GPVAL_TERM_YSIZE
# necessary to scale with aspect ratio of terminal
# +0.0 to force floating point divison
AAspect = GPVAL_TERM_XSIZE / (GPVAL_TERM_YSIZE +0.0)
# more coordinate transformation functions
a1x(ax,AA,HL,HA) = aFracScrX(ax) + HL/cos(HA)*cos(180-HA+AA)
a1y(ay,AA,HL,HA) = aFracScrY(ay) + HL/cos(HA)*sin(180-HA+AA)*AAspect
a2x(ax,AA,HL,HA,BA) = aFracScrX(ax) + HL\
*(1-tan(HA)/tan(BA))*cos(180+AA)
a2y(ay,AA,HL,HA,BA) = aFracScrY(ay) + HL\
*(1-tan(HA)/tan(BA))*sin(180+AA)*AAspect
a3x(ax,AA,HL,HA) = aFracScrX(ax) + HL/cos(HA)*cos(180+HA+AA)
a3y(ay,AA,HL,HA) = aFracScrY(ay) + HL/cos(HA)*sin(180+HA+AA)*AAspect
# here comes the loop to create a few arrow heads
do for [i=1:8] {
AA = i*45 # ArrowAngle 0° points to the right
ax = 8*cos(i*45)
ay = 8*sin(i*45)
set object i polygon \
from screen aFracScrX(ax),aFracScrY(ay) \
to screen a1x(ax,AA,HL,HA),a1y(ay,AA,HL,HA) \
to screen a2x(ax,AA,HL,HA,BA),a2y(ay,AA,HL,HA,BA) \
to screen a3x(ax,AA,HL,HA),a3y(ay,AA,HL,HA) \
to screen aFracScrX(ax),aFracScrY(ay) \
fillstyle solid fc rgb "red"
}
# plot something to visualize the objects
plot 0 notitle
####### EOF
|
|
From: Ethan M. <eam...@gm...> - 2016-08-05 20:43:39
|
Note that arrows can now (version 5) be specified in the form:
set arrow {<tag>} from <position> length <coord> angle <ang>
This is particularly useful for the case at hand.
On Fri, Aug 5, 2016 at 10:44 AM, BBands <bb...@gm...> wrote:
> You can make a really short arrow, this one points to the upper right:
>
> set arrow from 0.98,0.98 to 1,1
>
> See 'help arrow" to format it to suit.
>
> John
>
> On Thu, Aug 4, 2016 at 6:35 PM, mikeincousa <mik...@gm...> wrote:
>
> > Is there some way to create a arrow head without the shaft?
> >
> > If so can it be rotated so it points to N, S, E, and W directions?
> >
> > If not any work arounds?
> >
> > There is some discussion of this in earlier versions, but I could not
> find
> > anything current.
> >
> ------------------------------------------------------------
> ------------------
> _______________________________________________
> gnuplot-info mailing list
> gnu...@li...
> Membership management via: https://lists.sourceforge.net/
> lists/listinfo/gnuplot-info
>
|
|
From: BBands <bb...@gm...> - 2016-08-05 17:44:09
|
You can make a really short arrow, this one points to the upper right:
set arrow from 0.98,0.98 to 1,1
See 'help arrow" to format it to suit.
John
On Thu, Aug 4, 2016 at 6:35 PM, mikeincousa <mik...@gm...> wrote:
> Is there some way to create a arrow head without the shaft?
>
> If so can it be rotated so it points to N, S, E, and W directions?
>
> If not any work arounds?
>
> There is some discussion of this in earlier versions, but I could not find
> anything current.
>
|
|
From: mikeincousa <mik...@gm...> - 2016-08-05 02:50:44
|
Is there some way to create a arrow head without the shaft? If so can it be rotated so it points to N, S, E, and W directions? If not any work arounds? There is some discussion of this in earlier versions, but I could not find anything current. -- View this message in context: http://gnuplot.10905.n7.nabble.com/Arrow-Heads-Only-No-shaft-tp20297.html Sent from the Gnuplot - User mailing list archive at Nabble.com. |
|
From: Ethan M. <eam...@gm...> - 2016-08-04 21:48:36
|
On Thu, Aug 4, 2016 at 4:28 AM, Grothausmann, Roman Dr. < gro...@mh...> wrote: > Many thanks Ethan for the quick implementation. Works great and has no > problems with SVGs: > https://github.com/romangrothausmann/KursgleicheNG/blob/484c > 11347d2bee7ad3c7503e5126d5d79f01a32a/windrose.gp > > Comparing the vector arrow heads and the label placement in my test > project, reveals a slight displacement for 180° rotations which decreases > in both directions towards 0°/360°. I wasn't able to compensate these with > offsets. > That is probably due to imperfect vertical centering in the svg terminal output. The various gnuplot terminals are not consistent in placing vertically-centered text; some align to the text baseline, some to the midline, and some to whatever is possible. I suspect the svg terminal could do a better job than it currently does. Ethan > > Thanks again for the quick feature implementation. > > On 03/08/16 22:32, Ethan Merritt wrote: > >> I like the idea, and it requires only a trivial amount of code, so... >> in today's CVS (version 5.1) >> >> http://gnuplot.sourceforge.net/demo_cvs/rotate_labels.html >> >> using theozh's test data: >> >> plot $Data using 1:2:3:4 with labels rotate variable >> >> >> Ethan >> >> On Tue, Aug 2, 2016 at 12:07 AM, Grothausmann, Roman Dr. >> <gro...@mh... <mailto:grothausmann.roman@mh- >> hannover.de>> >> wrote: >> >> Dear mailing list members, >> >> >> Is there any way to plot labels rotated according to angles given by >> a data >> column? >> All I could find is: >> plot ... with labels rotate by X >> which, as I understand, only allows a fixed rotation for all labels. >> >> Any help or hints are very much appreciated >> Roman >> >> ------------------------------------------------------------ >> ------------------ >> _______________________________________________ >> gnuplot-info mailing list >> gnu...@li... <mailto:gnu...@li... >> rceforge.net> >> Membership management via: >> https://lists.sourceforge.net/lists/listinfo/gnuplot-info >> >> >> >> |
|
From: Grothausmann, R. Dr. <gro...@mh...> - 2016-08-04 11:28:17
|
Many thanks Ethan for the quick implementation. Works great and has no problems with SVGs: https://github.com/romangrothausmann/KursgleicheNG/blob/484c11347d2bee7ad3c7503e5126d5d79f01a32a/windrose.gp Comparing the vector arrow heads and the label placement in my test project, reveals a slight displacement for 180° rotations which decreases in both directions towards 0°/360°. I wasn't able to compensate these with offsets. Thanks again for the quick feature implementation. On 03/08/16 22:32, Ethan Merritt wrote: > I like the idea, and it requires only a trivial amount of code, so... > in today's CVS (version 5.1) > > http://gnuplot.sourceforge.net/demo_cvs/rotate_labels.html > > using theozh's test data: > > plot $Data using 1:2:3:4 with labels rotate variable > > > Ethan > > On Tue, Aug 2, 2016 at 12:07 AM, Grothausmann, Roman Dr. > <gro...@mh... <mailto:gro...@mh...>> > wrote: > > Dear mailing list members, > > > Is there any way to plot labels rotated according to angles given by a data > column? > All I could find is: > plot ... with labels rotate by X > which, as I understand, only allows a fixed rotation for all labels. > > Any help or hints are very much appreciated > Roman > > ------------------------------------------------------------------------------ > _______________________________________________ > gnuplot-info mailing list > gnu...@li... <mailto:gnu...@li...> > Membership management via: > https://lists.sourceforge.net/lists/listinfo/gnuplot-info > > |
|
From: Grothausmann, R. Dr. <gro...@mh...> - 2016-08-04 11:21:21
|
Many thanks theozh! The way of assigning values from data to variables through empty plot commands was completely new to me. It works great for wxt (https://github.com/romangrothausmann/KursgleicheNG/blob/8c9eb5c69e77da7e9102beefa8c139d409717719/windrose.gp), but even though SVG supports rotated labels, the "empty plots" cause SVG end-tags for groups that have no start-tag which results in invalid SVGs. Is that expected? On 02/08/16 23:04, theozh wrote: > well, you could do it with setting labels... > > However, the example below is a bit a cumbersome workaround, but it > seems to do the job in a wxt terminal. > - the first data column is used to define the position > - the second data column gives the label text > - the third data column defines the rotation > The first 3 plot command are not plotting anything but extracting > numbers and text into the variables a,b,c. > > Hope this helps... > Maybe there is a more elegant version? > > > reset > > $Data <<EOD > 1 one -30 > 2 two -60 > 3 three -90 > 4 four -120 > 5 five -150 > 6 six -180 > 7 seven -210 > 8 eight -240 > 9 nine -270 > 10 ten -300 > 11 eleven -330 > 12 twelve -360 > EOD > > set xrange [0:10] > set yrange [0:10] > set size square > unset xtics > unset ytics > n = 12. # . for floating point division > set angles degrees > do for [i=1:n] { > plot $Data u 1:(a=$1,0/0) every 1:1:i-2:0:i-1:0 notitle; > plot $Data u 1:(b=stringcolumn(2),0/0) every 1:1:i-2:0:i-1:0 notitle; > plot $Data u 1:(c=$3,0/0) every 1:1:i-1:0:i-1:0 notitle; > set label i center at (5+5*cos(-i/n*360+90)),(5+5*sin(-i/n*360+90))\ > sprintf("%s",b) rotate by c font "Arial,20"; > } > > plot $Data u 1:1 notitle # or whatever else you need to plot > |
|
From: mikeincousa <mik...@gm...> - 2016-08-03 23:35:24
|
Plot size: 11 x 17 Terminal:Windows Goal: an empty box in the lower right > set object 2 rectangle at 20, 0 size 10,1 fs empty border -1 lw 2 #works, but with the dimensions determined by trial and error x, and y for width and height do not agree with plot scale dimensions of 11 x 17 Same problem with from and to. #interactive terminal quirk? #something to do with coordinate system? (using default)? #"border" is confusing. Seems that [rectangle] border as contrasted with the plot border is actually set by choosing a default line type? I went to plot border first. -- View this message in context: http://gnuplot.10905.n7.nabble.com/Setting-Rectangle-Problems-tp20290.html Sent from the Gnuplot - User mailing list archive at Nabble.com. |
|
From: Ethan M. <eam...@gm...> - 2016-08-03 20:32:53
|
I like the idea, and it requires only a trivial amount of code, so...
in today's CVS (version 5.1)
http://gnuplot.sourceforge.net/demo_cvs/rotate_labels.html
using theozh's test data:
plot $Data using 1:2:3:4 with labels rotate variable
Ethan
On Tue, Aug 2, 2016 at 12:07 AM, Grothausmann, Roman Dr. <
gro...@mh...> wrote:
> Dear mailing list members,
>
>
> Is there any way to plot labels rotated according to angles given by a
> data column?
> All I could find is:
> plot ... with labels rotate by X
> which, as I understand, only allows a fixed rotation for all labels.
>
> Any help or hints are very much appreciated
> Roman
>
>
> ------------------------------------------------------------------------------
> _______________________________________________
> gnuplot-info mailing list
> gnu...@li...
> Membership management via:
> https://lists.sourceforge.net/lists/listinfo/gnuplot-info
>
|
|
From: Francesco L. R. <kec...@gm...> - 2016-08-03 08:41:20
|
Hello, I would like to use gnuplot to plot my 2d function ch(x,y) [obtained by a pde solver, FreeFem++]. My datafile is structured in this way: x1 y1 ch(x1,y1) x2 x2 ch(x2,y2) x3 y3 ch(x3,y3) x1 y1 ch(x1,y1) x4 y4 ch(x4,y4) ... ... ... ... where I have the value of my function at the 3 vertices of every triangle which constitutes my (triangular, not structured) mesh (see figure here http://i65.tinypic.com/2mydkq9.jpg). What I would like to get is two separate figures: 1. something like this for the surface, with a colorbar as a legend: http://i68.tinypic.com/egvkzr.jpg and 2. something like this for contour lines, with a colorbar as a legend: http://i67.tinypic.com/msgepg.jpg How can I get these two figures with gnuplot? I've tried for example doing the first one : set palette rgbformulae 33,13,10 set xrange [0: 0.25] set yrange [0: 0.20] set view map splot "mydatafile.txt" w l pal but the triangles inside are white (not filled with colors) and only the edges of the triangles are coloured. How about the contour lines? Thank you in advance, Keccogrin |
|
From: D <dcm...@we...> - 2016-08-03 07:53:05
|
Yes, ok, it's not a bug. But from a beginners perspective I just wanted to plot a graph and at least in log mode I had to "set sample <n>" for the graph to reach the bottom and top axis and be fully drawn. There's basically no fast way to know that this was necessary. I don't know but maybe at least some helpful warning should appear when one uses a certain xy range, specially in log mode (I know it is not limited to log mode)? Also of course the log ticks looked ok up to a certain xrange and I had to use: "set mxtics 10 # see "help set mxtics" set mytics 10" Seems also not beginner friendly or kinda buggy (because it works to a certain range and then not). Anyways I just see possible improvements to be made here for a next version. On 03.08.2016 00:08, Ethan Merritt wrote: > There is no bug here - you are fighting the limits of floating point > precision. > Consider the final steps that are sampled as x approaches 10000. > For linear sampling in steps of 100 > > f(9800) is 490000.000000002 > f(9900) is 990000.00000001 > f(10000) is inf (divide by zero at IEEE floating precision) > > So f(9900) is the last point that shows on the plot, and that value is > less > than the y range you have chosen. The function reaches ymax (10^7) at > f(9990.) > To catch that on your plot you must sample finely enough to > distinguish 9990 from 10000. > > And that's for linear sampling. In logscale the sampling must be even > finer. > The program selects even samples along the x axis (even spacing on > log(x)). > So most of the samples are at low values of x. > > On Sun, Jul 31, 2016 at 5:16 AM, D <dcm...@we... > <mailto:dcm...@we...>> wrote: > > Thanks. I had to 'set sample' to 500000 for gnuplot to plot the > whole line (slightly different xy range and the line goes to the > bottom). Works in linear mode without the need for any 'set > sample', wonder why the log mode requires that at all. Maybe you > should fix that for v5.1 too. > > > On 29.07.2016 20:52, Ethan Merritt wrote: >> 1) version 5.0: >> set mxtics 10 # see "help set mxtics" >> set mytics 10 >> >> version 5.1 >> currently a bug. thanks for the report >> >> 2) set sample 10000 >> Or else define the functions as parametric so that the sample is >> independent of the x/y precision. >> But increasing the number of samples is easier. >> >> On Fri, Jul 29, 2016 at 11:28 AM, D <dcm...@we... >> <mailto:dcm...@we...>> wrote: >> >> Hi, using: >> >> set terminal pngcairo truecolor enhanced font "arial,11" >> fontscale 1.0 >> size 1000,1000 >> set output "test.png" >> >> set log xy >> #set logscale xy >> >> set xrange [100:1e7] >> set yrange [100:1e7] >> >> set grid xtics ytics mxtics mytics lt 0 lw 1 lc rgb "#000000" >> >> f(x) = x/ (1-0.0001*x) >> fi(x) = x/(1/(1-0.0001*x)) >> g(x) = x/ (1-0.0000001*x) >> gi(x) = x/(1/(1-0.0000001*x)) >> id(x) = x >> >> plot f(x) lt 2 lc rgb "#ff0000" lw 1 , \ >> fi(x) lt 2 lc rgb "#ff0000" lw 1 , \ >> g(x) lt 2 lc rgb "#ff0000" lw 1 , \ >> gi(x) lt 2 lc rgb "#ff0000" lw 1 , \ >> id(x) dashtype 2 lc rgb "#000000" lw 1 >> >> 1) the grid tick lines look either incorrect or at least not >> to what >> they look up to [100:1e6]. How can I make them work with >> [100:1e7] ? >> 2) the plot of the lines does neither go to the bottom >> (fi,gi), nor to >> the top (f,g), as expected. How to fix? >> >> ------------------------------------------------------------------------------ >> _______________________________________________ >> gnuplot-info mailing list >> gnu...@li... >> <mailto:gnu...@li...> >> Membership management via: >> https://lists.sourceforge.net/lists/listinfo/gnuplot-info >> >> > > |
|
From: theozh <th...@gm...> - 2016-08-03 06:07:23
|
sorry, minor correction: In the following line it should read of course 'a' instead of 'i' within cos() and sin() for the position of the label. set label i center at (5+5*cos(-a/n*360+90)),(5+5*sin(-a/n*360+90))\ |
|
From: Ethan M. <eam...@gm...> - 2016-08-02 22:08:26
|
There is no bug here - you are fighting the limits of floating point precision. Consider the final steps that are sampled as x approaches 10000. For linear sampling in steps of 100 f(9800) is 490000.000000002 f(9900) is 990000.00000001 f(10000) is inf (divide by zero at IEEE floating precision) So f(9900) is the last point that shows on the plot, and that value is less than the y range you have chosen. The function reaches ymax (10^7) at f(9990.) To catch that on your plot you must sample finely enough to distinguish 9990 from 10000. And that's for linear sampling. In logscale the sampling must be even finer. The program selects even samples along the x axis (even spacing on log(x)). So most of the samples are at low values of x. On Sun, Jul 31, 2016 at 5:16 AM, D <dcm...@we...> wrote: > Thanks. I had to 'set sample' to 500000 for gnuplot to plot the whole line > (slightly different xy range and the line goes to the bottom). Works in > linear mode without the need for any 'set sample', wonder why the log mode > requires that at all. Maybe you should fix that for v5.1 too. > > > On 29.07.2016 20:52, Ethan Merritt wrote: > > 1) version 5.0: > set mxtics 10 # see "help set mxtics" > set mytics 10 > > version 5.1 > currently a bug. thanks for the report > > 2) set sample 10000 > Or else define the functions as parametric so that the sample is > independent of the x/y precision. > But increasing the number of samples is easier. > > On Fri, Jul 29, 2016 at 11:28 AM, D <dcm...@we...> wrote: > >> Hi, using: >> >> set terminal pngcairo truecolor enhanced font "arial,11" fontscale 1.0 >> size 1000,1000 >> set output "test.png" >> >> set log xy >> #set logscale xy >> >> set xrange [100:1e7] >> set yrange [100:1e7] >> >> set grid xtics ytics mxtics mytics lt 0 lw 1 lc rgb "#000000" >> >> f(x) = x/ (1-0.0001*x) >> fi(x) = x/(1/(1-0.0001*x)) >> g(x) = x/ (1-0.0000001*x) >> gi(x) = x/(1/(1-0.0000001*x)) >> id(x) = x >> >> plot f(x) lt 2 lc rgb "#ff0000" lw 1 , \ >> fi(x) lt 2 lc rgb "#ff0000" lw 1 , \ >> g(x) lt 2 lc rgb "#ff0000" lw 1 , \ >> gi(x) lt 2 lc rgb "#ff0000" lw 1 , \ >> id(x) dashtype 2 lc rgb "#000000" lw 1 >> >> 1) the grid tick lines look either incorrect or at least not to what >> they look up to [100:1e6]. How can I make them work with [100:1e7] ? >> 2) the plot of the lines does neither go to the bottom (fi,gi), nor to >> the top (f,g), as expected. How to fix? >> >> >> ------------------------------------------------------------------------------ >> _______________________________________________ >> gnuplot-info mailing list >> gnu...@li... >> Membership management via: >> https://lists.sourceforge.net/lists/listinfo/gnuplot-info >> > > > |
|
From: theozh <th...@gm...> - 2016-08-02 21:05:00
|
well, you could do it with setting labels...
However, the example below is a bit a cumbersome workaround, but it
seems to do the job in a wxt terminal.
- the first data column is used to define the position
- the second data column gives the label text
- the third data column defines the rotation
The first 3 plot command are not plotting anything but extracting
numbers and text into the variables a,b,c.
Hope this helps...
Maybe there is a more elegant version?
reset
$Data <<EOD
1 one -30
2 two -60
3 three -90
4 four -120
5 five -150
6 six -180
7 seven -210
8 eight -240
9 nine -270
10 ten -300
11 eleven -330
12 twelve -360
EOD
set xrange [0:10]
set yrange [0:10]
set size square
unset xtics
unset ytics
n = 12. # . for floating point division
set angles degrees
do for [i=1:n] {
plot $Data u 1:(a=$1,0/0) every 1:1:i-2:0:i-1:0 notitle;
plot $Data u 1:(b=stringcolumn(2),0/0) every 1:1:i-2:0:i-1:0 notitle;
plot $Data u 1:(c=$3,0/0) every 1:1:i-1:0:i-1:0 notitle;
set label i center at (5+5*cos(-i/n*360+90)),(5+5*sin(-i/n*360+90))\
sprintf("%s",b) rotate by c font "Arial,20";
}
plot $Data u 1:1 notitle # or whatever else you need to plot
|
|
From: Grothausmann, R. Dr. <gro...@mh...> - 2016-08-02 07:08:07
|
Dear mailing list members, Is there any way to plot labels rotated according to angles given by a data column? All I could find is: plot ... with labels rotate by X which, as I understand, only allows a fixed rotation for all labels. Any help or hints are very much appreciated Roman |
|
From: D <dcm...@we...> - 2016-07-31 12:16:30
|
Thanks. I had to 'set sample' to 500000 for gnuplot to plot the whole line (slightly different xy range and the line goes to the bottom). Works in linear mode without the need for any 'set sample', wonder why the log mode requires that at all. Maybe you should fix that for v5.1 too. On 29.07.2016 20:52, Ethan Merritt wrote: > 1) version 5.0: > set mxtics 10 # see "help set mxtics" > set mytics 10 > > version 5.1 > currently a bug. thanks for the report > > 2) set sample 10000 > Or else define the functions as parametric so that the sample is > independent of the x/y precision. > But increasing the number of samples is easier. > > On Fri, Jul 29, 2016 at 11:28 AM, D <dcm...@we... > <mailto:dcm...@we...>> wrote: > > Hi, using: > > set terminal pngcairo truecolor enhanced font "arial,11" fontscale 1.0 > size 1000,1000 > set output "test.png" > > set log xy > #set logscale xy > > set xrange [100:1e7] > set yrange [100:1e7] > > set grid xtics ytics mxtics mytics lt 0 lw 1 lc rgb "#000000" > > f(x) = x/ (1-0.0001*x) > fi(x) = x/(1/(1-0.0001*x)) > g(x) = x/ (1-0.0000001*x) > gi(x) = x/(1/(1-0.0000001*x)) > id(x) = x > > plot f(x) lt 2 lc rgb "#ff0000" lw 1 , \ > fi(x) lt 2 lc rgb "#ff0000" lw 1 , \ > g(x) lt 2 lc rgb "#ff0000" lw 1 , \ > gi(x) lt 2 lc rgb "#ff0000" lw 1 , \ > id(x) dashtype 2 lc rgb "#000000" lw 1 > > 1) the grid tick lines look either incorrect or at least not to what > they look up to [100:1e6]. How can I make them work with [100:1e7] ? > 2) the plot of the lines does neither go to the bottom (fi,gi), nor to > the top (f,g), as expected. How to fix? > > ------------------------------------------------------------------------------ > _______________________________________________ > gnuplot-info mailing list > gnu...@li... > <mailto:gnu...@li...> > Membership management via: > https://lists.sourceforge.net/lists/listinfo/gnuplot-info > > |
|
From: Dave H. <da...@ho...> - 2016-07-30 13:39:56
|
On Fri, 29 Jul 2016, Ethan A Merritt wrote: [ ... ] > > What I really want to see is the parabola crossing the straight line, > > around pi * 16. so where have I stuffed up? > > The default range on x is [-10:10], which is what you have. > You asked for xtics starting at 0 and going to 100, which you also have. > IOW you got just what you asked for. > > Maybe you intended "set xrange" rather than "set xtics"? Bingo! Many thanks. -- Dave Horsfall DTM (VK2KFU) "Those who don't understand security will suffer." |
|
From: Joseph G. <jos...@ya...> - 2016-07-30 07:32:50
|
The idea is to get user input, do some calculations and use the result on a plot, right?If you use R then there are demos here on how to do that:
CRAN - Package Rgnuplot
|
| |
CRAN - Package Rgnuplot
| |
|
For Python, C, shell scripts, etc there is similar stuff online.
Sometimes the calculations are too complex or the data has to be prepared before the plot, fortunately gnuplot is very easy to be called from any language or environment.
From: theozh <th...@gm...>
To: gnu...@li...
Sent: Friday, July 29, 2016 4:11 PM
Subject: [Gnuplot-info] Interactive user input with gnuplot
Is there a way in gnuplot to interactively enter a few values, i.e.
numbers and strings?
The idea is to enable users which are not familiar with gnuplot and do
not want to (are not able to or should not) edit a gnuplot script to
generate plots which require a few custom values which are then stored
in user variables for further use in the script.
The command "pause" allows some very limited user input
pause mouse keypress "Type a letter"
# Returning the ASCII value of the key pressed in MOUSE_KEY
or
pause -1 "Hit a key to continue"
But I am looking for a simple popup window, e.g. like:
+------------------+
| Sample: ....... |
| Start: ....... |
| Stop: ....... |
| |
| OK Cancel |
+------------------+
Any ways to achieve this?
------------------------------------------------------------------------------
_______________________________________________
gnuplot-info mailing list
gnu...@li...
Membership management via: https://lists.sourceforge.net/lists/listinfo/gnuplot-info
|
|
From: Ethan A M. <EAM...@gm...> - 2016-07-30 04:48:34
|
On Saturday, 30 July 2016 01:50:40 PM Dave Horsfall wrote: > Gnuplot 5.0.4, on MacOS 10.11.6. > > For reasons that are not particularly germane, I am trying to determine > the area of a square vs. a circle, given a piece of string of length "x". > I have worked it out in simple maths, but I want to plot it. > > gnuplot> set xtics 0,1,100 > gnuplot> plot (x*x)/16, pi * x > > But no matter what I do, I get a partial graph, no xtics on the left, > extending to 10 on the right, with the expected parabola and angled line > intersecting at x=0. > > What I really want to see is the parabola crossing the straight line, > around pi * 16. so where have I stuffed up? The default range on x is [-10:10], which is what you have. You asked for xtics starting at 0 and going to 100, which you also have. IOW you got just what you asked for. Maybe you intended "set xrange" rather than "set xtics"? |
|
From: Ethan A M. <EAM...@gm...> - 2016-07-30 03:53:53
|
On Friday, 29 July 2016 11:07:29 PM Alan Corey wrote: > On 7/29/16, Ethan Merritt <eam...@gm...> wrote: > > Use the "stats" command. If you only need to know the y value range, that > > would be > > > > stats "outvals.tab" using 2 > > Thank you, that's close. What it gets though are the min/max of the > data rather than the limits of the plot. For example 17.6 - 31.9 > rather than 16 - 32. I imagine there's a relatively simple formula > that sets the plot limits to round numbers? I think those are what I > should put through the * 1.8 + 32 conversion. I probably can't access > the plot limits but I can derive them over again from the data limits > if I know the formula. Not a formula. By default the axis range is extended to the next tic mark. What that is depends on "set ytics". If you do not want the axis range to extend beyond the actual data, you can use the keyword "noextend". I.e. set yrange [*:*] noextend In that case the axis range will exactly match the min/max of the data y coordinates,. See "help noextend" Ethan |
|
From: Dave H. <da...@ho...> - 2016-07-30 03:50:53
|
Gnuplot 5.0.4, on MacOS 10.11.6. For reasons that are not particularly germane, I am trying to determine the area of a square vs. a circle, given a piece of string of length "x". I have worked it out in simple maths, but I want to plot it. gnuplot> set xtics 0,1,100 gnuplot> plot (x*x)/16, pi * x But no matter what I do, I get a partial graph, no xtics on the left, extending to 10 on the right, with the expected parabola and angled line intersecting at x=0. What I really want to see is the parabola crossing the straight line, around pi * 16. so where have I stuffed up? Thanks. -- Dave Horsfall DTM (VK2KFU) "Those who don't understand security will suffer." |