Page Menu
Home
HEPForge
Search
Configure Global Search
Log In
Files
F11221471
gmllongtest.mp
No One
Temporary
Actions
Download File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Award Token
Flag For Later
Size
9 KB
Subscribers
None
gmllongtest.mp
View Options
% gmllongtest.mp -- do not edit, generated automatically from gmllongtest.tex
compare_filedate("1998/11/02","1998/11/02","0.40");
defaultfont:="cmr10";
verbatimtex \documentclass [10pt]{article}
\input gmllongtest.ltp
\begin {document} etex
init_numbers(
btex$-$etex,
btex$1$etex,
btex${\times }10$etex,
btex${}^-$etex,
btex${}^2$etex);
message "These should be 1, 20, 300, 4e10, 5e-13, -6, -7e8, -8e-2.";
showfloat #1, #20, #300, #4e10, #5e-13, #-6, #-7e8, #-8e-2;
message "This should be 1.2345678.";
showfloat #1.2345678;
newcolor snow ("255 250 250");
newcolor ghost white ("248 248 255");
newcolor white smoke ("245 245 245");
newcolor gainsboro ("220 220 220");
newcolor floral white ("255 250 240");
newcolor old lace ("253 245 230");
newcolor linen ("250 240 230");
newcolor antique white ("250 235 215");
newcolor papaya whip ("255 239 213");
newcolor blanched almond ("255 235 205");
newcolor bisque ("255 228 196");
newcolor peach puff ("255 218 185");
newcolor navajo white ("255 222 173");
newcolor moccasin ("255 228 181");
newcolor cornsilk ("255 248 220");
newcolor ivory ("255 255 240");
newcolor lemon chiffon ("255 250 205");
newcolor seashell ("255 245 238");
newcolor honeydew ("240 255 240");
newcolor mint cream ("245 255 250");
newcolor azure ("240 255 255");
newcolor alice blue ("240 248 255");
newcolor lavender ("230 230 250");
newcolor lavender blush ("255 240 245");
newcolor misty rose ("255 228 225");
newcolor white ("255 255 255");
newcolor black ("000 000 000");
newcolor dark slate gray ("047 079 079");
newcolor dim gray ("105 105 105");
newcolor slate gray ("112 128 144");
newcolor light slate gray ("119 136 153");
newcolor medium gry ("190 190 190");
newcolor light gray ("211 211 211");
newcolor midnight blue ("025 025 112");
newcolor navy ("000 000 128");
newcolor navy blue ("000 000 128");
newcolor cornflower blue ("100 149 237");
newcolor dark slate blue ("072 061 139");
newcolor slate blue ("106 090 205");
newcolor medium slate blue ("123 104 238");
newcolor light slate blue ("132 112 255");
newcolor medium blue ("000 000 205");
newcolor royal blue ("065 105 225");
newcolor blue ("000 000 255");
newcolor dodger blue ("030 144 255");
newcolor deep sky blue ("000 191 255");
newcolor sky blue ("135 206 235");
newcolor light sky blue ("135 206 250");
newcolor steel blue ("070 130 180");
newcolor light steel blue ("176 196 222");
newcolor light blue ("173 216 230");
newcolor powder blue ("176 224 230");
newcolor pale turquoise ("175 238 238");
newcolor dark turquoise ("000 206 209");
newcolor medium turquoise ("072 209 204");
newcolor turquoise ("064 224 208");
newcolor cyan ("000 255 255");
newcolor light cyan ("224 255 255");
newcolor cadet blue ("095 158 160");
newcolor medium aquamarine ("102 205 170");
newcolor aquamarine ("127 255 212");
newcolor dark green ("000 100 000");
newcolor dark olive green ("085 107 047");
newcolor dark sea green ("143 188 143");
newcolor sea green ("046 139 087");
newcolor medium sea green ("060 179 113");
newcolor light sea green ("032 178 170");
newcolor pale green ("152 251 152");
newcolor spring green ("000 255 127");
newcolor lawn green ("124 252 000");
newcolor green ("000 255 000");
newcolor chartreuse ("127 255 000");
newcolor medium spring green ("000 250 154");
newcolor green yellow ("173 255 047");
newcolor lime green ("050 205 050");
newcolor yellow green ("154 205 050");
newcolor forest green ("034 139 034");
newcolor olive drab ("107 142 035");
newcolor dark khaki ("189 183 107");
newcolor khaki ("240 230 140");
newcolor pale goldenrod ("238 232 170");
newcolor light goldenrod yellow ("250 250 210");
newcolor light yellow ("255 255 224");
newcolor yellow ("255 255 000");
newcolor gold ("255 215 000");
newcolor light goldenrod ("238 221 130");
newcolor goldenrod ("218 165 032");
newcolor dark goldenrod ("184 134 011");
newcolor rosy brown ("188 143 143");
newcolor indian red ("205 092 092");
newcolor saddle brown ("139 069 019");
newcolor sienna ("160 082 045");
newcolor peru ("205 133 063");
newcolor burlywood ("222 184 135");
newcolor beige ("245 245 220");
newcolor wheat ("245 222 179");
newcolor sandy brown ("244 164 096");
newcolor medium tan ("210 180 140");
newcolor chocolate ("210 105 030");
newcolor firebrick ("178 034 034");
newcolor brown ("165 042 042");
newcolor dark salmon ("233 150 122");
newcolor salmon ("250 128 114");
newcolor light salmon ("255 160 122");
newcolor orange ("255 165 000");
newcolor dark orange ("255 140 000");
newcolor coral ("255 127 080");
newcolor light coral ("240 128 128");
newcolor tomato ("255 099 071");
newcolor orange red ("255 069 000");
newcolor red ("255 000 000");
newcolor hot pink ("255 105 180");
newcolor deep pink ("255 020 147");
newcolor pink ("255 192 203");
newcolor light pink ("255 182 193");
newcolor pale violet red ("219 112 147");
newcolor maroon ("176 048 096");
newcolor medium violet red ("199 021 133");
newcolor violet red ("208 032 144");
newcolor magenta ("255 000 255");
newcolor violet ("238 130 238");
newcolor plum ("221 160 221");
newcolor orchid ("218 112 214");
newcolor medium orchid ("186 085 211");
newcolor dark orchid ("153 050 204");
newcolor dark violet ("148 000 211");
newcolor blue violet ("138 043 226");
newcolor purple ("160 032 240");
newcolor medium purple ("147 112 219");
newcolor thistle ("216 191 216");
newcolor dark gray ("169 169 169");
newcolor dark blue ("000 000 139");
newcolor dark cyan ("000 139 139");
newcolor dark magenta ("139 000 139");
newcolor dark red ("139 000 000");
newcolor light green ("144 238 144");
if true:
savecurrentpen;
beginfig(1);
pickup _cpen; setpencolor;
verbatimtex\begingroup etex
savecurrentpen; savepencolor;
save tmp;
save unitlength; unitlength:=2.84526pt;
verbatimtex\unitlength 2.84526pt{}etex
tracingsets:=1; tracingonline:=1;
picture px; px =
begingraph(12cm,10cm)
graphrange (#0,#1.7), (#10,??);
fromfile "gmllongtest.dat":
% A curve to be plotted in one line
table plot(u)(); showdata u;
% data points with x and y error bars
for l withinblock: get x,y,h; plot(t) z vbar h hbar (h over two); endfor
showdata t;
% Two named datasets
tables plot(a1,a2)();
showdata a1,a2;
for l withinblock: get x,y; hist(s) (x, y plus #6); endfor
showdata s;
endfrom
% A band between two curves.
fill from(a1|a2\) linked(smoothly,straight)
withbackground
(spectrum(50)(red,magenta,blue) xscaled width yscaled height)
withlegend "Band";
% A small histogram that has been read in as horizontal bars,
% drawn with an offset in absolute coordinates. The label points to
% the midpoint of the 2nd bar, that is point#1 on part#1 of the path
% set.
calculate bb(s) (x,#6);
draw piecewise cyclic from(s,bb/\) shifted (5mm,0);
phantom from(bb$1\) shifted (5mm,0)
withlabel.bot("Histogram", on curve at 1);
% A triangle in graph coordinates
fill plot((#3,#4),(#9,#5),(#6,#4)) withcolor green
withlegend "Triangle" outlined;
% A curve with circles at the data points. The first label refers to
% point#2 on the first drawn path, the second one to the point where
% it intersects x=0.
draw from(u) dashed evenly withcolor red
withsymbol(circle scaled 3mm) withlegend "Curve"
withdotlabel.urt("Maximum", on curve at 2)
withdotlabel.lft(btex $x=0$ etex, on curve at (#0,??) shifted (-3mm,0));
% A label at a point in graph coords
dotlabel.lrt(image(drawarrow (1cm,-1cm)--origin;
label.lrt(btex $(8,6)$ etex, (1cm,-1cm))),
on graph at (#8,#6));
% Horizontal and vertical error bars, with square symbols
picture sq; sq =
image(draw square scaled 3mm; fill square scaled 2mm);
draw piecewise from(t) withcolor .5white withsymbol sq withticks
withlegend btex Error bars etex;
% Another triangle, completely in absolute coords
draw(3cm,4cm)--(2cm,5cm)--(1cm,1cm)--cycle
dashed withdots scaled .5 withpenscale 2
withdotlabel.ulft("Corner", on curve at 2);
% A histogram, calculated directly instead of using a file, drawn with
% dots at the reference points. The color has been read from rgb.txt
hist(c) (#5,#4), (#5.5,#4.8), (#6,#5.4), (#6.5,#4.5), (#7,??);
calculate cb(c) (x,#3.5);
fill piecewise from(c,cb/\) hatched withstripes rotated 30
withcolor orange
withshadow shifted (2mm,-3mm) withcolor .8[orange,white]
withlegend "Histogram";
phantom from(c) withsymbol(fshape(circle scaled 2mm)() colored red)
withlegend "Values";
% A closed shape
draw cyclic plot(
(#8,#2),(#9,#2.1),(#10,#2.5),(#9,#2.9),
(#8,#3),(#7,#2.9),(#6,#2.5),(#7,#2.1))
dashed withdashdots linked smoothly;
% A label picture that shows up at the left margin (slightly offset)
label.rt(image(drawarrow (1cm,0)--origin;
label.rt(btex$6.5$etex, (1cm,0))),
on graph at (??,#6.5) shifted (3mm,0));
% Data points with cumulative errors
fromfile "gmllongtest.dat":
for l withinblock:
get x,y,a,b; plot(r1) z vbar a; plot(r2) z vbar (a plus b);
endfor
endfrom;
% Outer labels and tick marks
label.top(btex\Large Test graph etex, out);
grid(labeled noticks rt, 10 iticks top, small iticks top) withlength 6mm;
defaultgrid(2); grid.bot(small oticks);
frame.llft;
% The legend
begingroup interim bboxmargin:=3mm;
label.urt(fdbox(thelegend)
(withcolor yellow withshadow shifted (2mm,-3mm) withcolor .8white)
()(), on graph at (#2,#5.2));
endgroup;
endgraph;
% Show the picture together with its bounding box
draw dbox(px)()();
verbatimtex\endgroup etex
endfig;
fi
end
File Metadata
Details
Attached
Mime Type
text/x-tex
Expires
Wed, May 14, 10:29 AM (1 d, 19 h)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
5111150
Default Alt Text
gmllongtest.mp (9 KB)
Attached To
rWHIZARDSVN whizardsvn
Event Timeline
Log In to Comment