Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.graphics.apps.gnuplot > #1742
| From | sfeam <sfeam@users.sourceforge.net> |
|---|---|
| Newsgroups | comp.graphics.apps.gnuplot |
| Subject | Re: Multiplot question |
| Followup-To | comp.graphics.apps.gnuplot |
| Date | 2013-04-04 12:08 -0700 |
| Organization | gnuplot development team |
| Message-ID | <kjkiv9$6fp$1@dont-email.me> (permalink) |
| References | <kirps0$4b7$1@dont-email.me> <ardr9rF4ocjU1@mid.individual.net> <kjjfgi$8dh$1@dont-email.me> |
Followups directed to: comp.graphics.apps.gnuplot
Dieter Britz wrote: > On Tue, 26 Mar 2013 15:57:01 +0100, Ingo Thies wrote: > >> Am 26.03.2013 10:30, schrieb Dieter Britz: >>> I have the following multiplot (stripped of labelling etc) >>> >>> set size square set multiplot layout 1, 2 plot 'vb.dat' w l lt 1, >>> 'vbp.dat' w p pt 7 ps 1 plot 'rz.dat' w l lt 1, 'rzp.dat' w p pt 7 ps 1 >>> >>> This produces two plots, both square, side by side, >>> and the same size. >>> >>> However, I would like the right-hand one stretched in the x-direction >>> by a factor, but to keep its vertical height. >>> >>> How do I do that please? >>> >>> >> You get the highest degree of freedom by setting the margins in screen >> coordinates > [...] > > I tried to follow your example but no luck. I have made up > a mini-example. Two data files, left.dat: > > 0.0 0.0 > 0.0 1.0 > 1.0 1.0 > 1.0 0.0 > 0.0 0.0 > > and an identical file right.dat (OK, I could have used just > the one), and this script: > > gnuplot << eoi > set term postscript enh eps 20 > set output 'leftright.eps' > unset key > set size square # ?? > set multiplot layout 1, 2 > set lmargin screen 0.05 > set rmargin screen 0.45 > set bmargin screen 0.05 > set tmargin screen 0.95 > plot 'left.dat' w l lt 1 > set lmargin screen 0.55 > set rmargin screen 0.95 > set bmargin screen 0.05 > set tmargin screen 0.95 > plot 'right.dat' w l lt 1 > quit > eoi > > This produces two squares, side by side, with extra > unwanted space at the top (?). The "set size square" > statement makes both plots square. If I leave it out, I get > two identical tall rectangles but I want the the left-hand > one square. > > So how do I modify the script to make the square on the right > a rectangle, stretched by a factor, say 1.33, in the x-direction? The "layout" option in multiplot is for the specific purpose of blocking out equal size fractions of the canvas, which is apparently not what you want. How about set multiplot set size ratio 1.0 set lmargin at screen 0.05 set bmargin at screen 0.05 set rmargin at screen 0.40 set tmargin at screen 0.40 plot 'left.dat' set size ratio 1.0/1.33 set rmargin at screen 0.95 set lmargin at screen 0.95 - 1.33*(0.35) set bmargin at screen 0.05 set tmargin at screen 0.40 plot 'left.dat' unset multiplot There may well be simpler ways, but I'm not clear on exactly what arrangement you want. Ethan
Back to comp.graphics.apps.gnuplot | Previous | Next — Previous in thread | Next in thread | Find similar
Multiplot question Dieter Britz <dieterhansbritz@gmail.com> - 2013-03-26 09:30 +0000
Re: Multiplot question Karl <mail.kfr@gmx.net> - 2013-03-26 14:21 +0100
Re: Multiplot question Dieter Britz <dieterhansbritz@gmail.com> - 2013-03-26 13:35 +0000
Re: Multiplot question Ingo Thies <ingo.thies@gmx.de> - 2013-03-26 15:57 +0100
Re: Multiplot question Dieter Britz <dieterhansbritz@gmail.com> - 2013-04-04 09:01 +0000
Re: Multiplot question sfeam <sfeam@users.sourceforge.net> - 2013-04-04 12:08 -0700
Re: Multiplot question Dieter Britz <dieterhansbritz@gmail.com> - 2013-04-05 08:44 +0000
Re: Multiplot question Christoph Bersch <usenet@bersch.net> - 2013-03-26 15:57 +0100
csiph-web