<html> <head> <!-- This file has been generated by unroff 1.0, 03/11/09 12:56:19. --> <!-- Do not edit! --> <STYLE TYPE="text/css"> <!-- A:link{text-decoration:none} A:visited{text-decoration:none} A:active{text-decoration:none} OL,UL,P,BODY,TD,TR,TH,FORM { font-family: arial,helvetica,sans-serif;; font-size:small; color: #333333; } H1 { font-size: x-large; font-family: arial,helvetica,sans-serif; } H2 { font-size: large; font-family: arial,helvetica,sans-serif; } H3 { font-size: medium; font-family: arial,helvetica,sans-serif; } H4 { font-size: small; font-family: arial,helvetica,sans-serif; } --> </STYLE> <title>ploticus: ploticus prefabs examples gallery</title> <body bgcolor=D0D0EE vlink=0000FF> <br> <br> <center> <table cellpadding=2 bgcolor=FFFFFF width=550><tr> <td> <table cellpadding=2 width=550><tr> <td><br><h2>Ploticus prefabs examples gallery</h2></td> <td align=right> <small> <a href="../doc/welcome.html"><img src="../doc/ploticus.gif" border=0></a><br> Version 2.41 Mar2009 </small><br><a href="../doc/prefabs.html">Prefabs</a> <td></tr></table> </td></tr> <td> <br> <br> <title>Manual page for Ploticus_prefabs_examples_gallery(PL)</title> </head> <body> <p> This page is a collection of all of the ploticus <a href="prefabs.html"> prefab </a> examples.<tt> </tt> <hr> <h2><a href="prefab_chron.html">chron</a></h2> <p> These examples all use <a href="prefab_chron.html"> the chron prefab.<tt> </tt> </a> All of these examples are included in the distribution (<tt>./pltestsuite/testpf_chron</tt>).<tt> </tt> <br><br><br> <h2>chron example 1 - dates</h2> <center><table cellpadding=2><tr> <td><img src="../gallery/prefab_img/chron1.gif"></td></tr> </table></center> <p> <pre> pl -prefab chron data=data14 x=1 y=2 datefmt=yy/mm/dd xinc="1 month" \ stubfmt=M xyears=yyyy yrange="0 25" barwidth=line color=red \ title="# hits per day" omitweekends=yes The data14 file: 00/12/21 1 00/12/22 1 00/12/23 2 00/12/27 1 ...etc. </pre> <h2>chron example 2 - dates - tabulated by week</h2> <center><table cellpadding=2><tr> <td><img src="../gallery/prefab_img/chron2.gif"></td></tr> </table></center> <p> <pre> pl -prefab chron data=data14 x=1 y=2 datefmt=yy/mm/dd xinc="1 month" \ stubfmt=M xyears=yyyy color=green tab=week title="# hits per week" </pre> <h2>chron example 3 - dates - tabulated by week</h2> <center><table cellpadding=2><tr> <td><img src="../gallery/prefab_img/chron3.gif"></td></tr> </table></center> <p> <pre> pl -prefab chron data=data19 x=2 y=1 datefmt=mmddyy xinc="1 month" \ stubfmt=M xyears=yyyy color=green tab=week include2=annot \ title="# website visitors per week" rectangle="1 1 4 2.5" ygrid=yes \ mode=line step=yes fill=red The data19 file: 18 071301 16 071401 15 071501 34 071601 ...etc. </pre> In the above example, notice that <b>rectangle</b> (new in 2.02) was used to set a smaller size, and a file containing script code for the annotation is included.<tt> </tt> <br><br><br> <h2>chron example 4 - dates - tabulated by month</h2> <center><table cellpadding=2><tr> <td><img src="../gallery/prefab_img/chron4.gif"></td></tr> </table></center> <p> <pre> pl -prefab chron data=data14 x=1 y=2 datefmt=yy/mm/dd xinc="1 month" \ stubfmt=M xyears=yyyy color=powderblue tab=month tabmode=first \ nearest=month barwidth=0.2 curve=yes </pre> <h2>chron example 5 - datetimes - tabulated by hour</h2> <center><table cellpadding=2><tr> <td><img src="../gallery/prefab_img/chron5.gif"></td></tr> </table></center> <p> <pre> pl -prefab chron data=data16 x=1 tab=hour datefmt=yy/mm/dd xinc="1 day" \ barwidth=line stubfmt=MMMdd unittype=datetime timefld=2 \ title="# hits per hour" The data16 file: 01/09/05 09:43:35 01/09/05 09:43:40 01/09/05 13:15:00 01/09/05 13:15:11 ...etc. Note that a file such as this (data13) could also be used, and timefld would not need to specified: 01/09/05.09:43:35 01/09/05.09:43:40 01/09/05.13:15:00 01/09/05.13:15:11 ..etc. </pre> <h2>chron example 6 - times - tabulated by hour</h2> <p> <center><table cellpadding=2><tr> <td><img src="../gallery/prefab_img/chron6.gif"></td></tr> </table></center> <p> <pre> pl -prefab chron data=data15 x=1 tab=hour unittype=time xinc="1 hour" \ nearest=hour barwidth=0.2 stubfmt=HHA \ title="# events per hour" color=coral The data15 file: 07:47:49 07:47:52 07:47:54 ..etc. </pre> <h2>chron example 7 - hourly temperature readings plotted for one week</h2> <center><table cellpadding=2><tr> <td><img src="../gallery/prefab_img/chron7.gif"></td></tr> </table></center> <p> <pre> pl -prefab chron data=data22 header=yes x=1 y=2 datefmt=mm/dd/yyyy \ xinc="1 day" mode=line unittype=datetime title="temperatures this week" The data22 file has data for one week and begins like this: datetime temp 12/08/2002.00:00 22 12/08/2002.06:00 24 12/08/2002.12:00 31 12/10/2002.00:00 30 </pre> <h2>chron example 8 - multiple curves</h2> <center><table cellpadding=2><tr> <td><img src="../gallery/prefab_img/chron8.gif"></td></tr> </table></center> <p> <pre> pl -prefab chron data=data24 header=yes unittype=datetime mode=line\ datefmt=mm/dd/yyyy x=dt y=airtemp y2=soiltemp y3=watertemp \ xinc="1 day" legendfmt=singleline The data24 file looks like this: dt airtemp soiltemp watertemp 12/08/2002.06:00 24 27 16 12/09/2002.00:00 25 27 16 12/10/2002.00:00 30 27 15 12/11/2002.00:00 32 32 15 12/12/2002.00:00 40 37 16 12/13/2002.00:00 19 27 15 12/14/2002.00:00 14 18 13 </pre> <p> In version 2.20 the ability to render multiple curves or bar sets was introduced.<tt> </tt> This can be done so long as tabulation is not being performed.<tt> </tt> <hr> <h2><a href="prefab_cumufrac.html">cumufrac</a></h2> <p> These examples use <a href="prefab_cumufrac.html"> the cumufrac prefab </a> and are included in the distribution (<tt>./pltestsuite/testpf_cumufrac</tt>).<tt> </tt> <br><br><br> <h2>cumufrac example 1</h2> <center><table cellpadding=2><tr> <td><img src="../gallery/prefab_img/cumufrac1.gif"></td></tr> </table></center> <p> <pre> pl -prefab cumufrac data=cumufrac.dat header=yes x=1 name="set 1" \ x2=2 name2="set 2" title="Cumulative fraction plot" The cumufrac.dat file looks like this: set1 set2 1.26 2.37 0.34 2.16 0.70 14.82 1.75 1.73 50.57 41.04 ... </pre> <h2>cumufrac example 2</h2> <center><table cellpadding=2><tr> <td><img src="../gallery/prefab_img/cumufrac2.gif"></td></tr> </table></center> <p> <pre> pl -prefab cumufrac data=cumufrac.dat header=yes logmode=log x=1 x2=2 \ title="Cumulative fraction plot w/ log scale" \ linedet="color=blue width=1.5" \ linedet2="color=orange width=1.5 style=2 dashscale=3" </pre> <hr> <h2><a href="prefab_dist.html">dist</a></h2> <p> These examples all use <a href="prefab_dist.html"> the dist prefab.<tt> </tt> </a> All of these examples are included in the distribution (<tt>./pltestsuite/testpf_dist</tt>).<tt> </tt> <br><br><br> <h2>dist example 1</h2> <p> <center><table cellpadding=2><tr> <td><img src="../gallery/prefab_img/dist1.gif"></td></tr> </table></center> <p> <pre> pl -prefab dist fld=1 data=data6 curve=yes binsize=0.05 \ barwidth=0.08 ygrid=yes data6 file: 0.017 0.269 0.178 ..etc. </pre> <h2>dist example 2</h2> <center><table cellpadding=2><tr> <td><img src="../gallery/prefab_img/dist2.gif"></td></tr> </table></center> <p> <pre> pl -prefab dist fld=1 data=data8 cats=yes yrange=0 \ stubvert=yes barwidth=0.05 ylbl="# Hits" order=rev data8 file: home kwindex details browseform ..etc. </pre> <hr> <h2><a href="prefab_heatmap.html">heatmap</a></h2> <p> These examples use the <a href="prefab_heatmap.html"> heatmap prefab </a> and are included in the distribution (<tt>./pltestsuite/testpf_heatmap</tt>).<tt> </tt> <br><br><br> <h2>heatmap example 1</h2> <img src="../gallery/prefab_img/heatmap1.gif"> <p> <pre> pl -prefab heatmap data=curve1.dat y=1 x=2 The curve1.dat file looks like this: 331 75 331.624 83.5518 332.105 88.7758 332.492 91.8638 ..etc. </pre> <p> The heatmap prefab's basic mode is to count instances. Here, the bin sizes in x and y are automatically determined, as is the breakdown for color coding.<tt> </tt> Default color scheme is used.<tt> </tt> These can all be given explicitly if desired.<tt> </tt> In this example, both X and Y are numeric.<tt> </tt> <br><br><br> <h2>heatmap example 2</h2> <img src="../gallery/prefab_img/heatmap2.gif"> <pre> pl -prefab heatmap data=snpmap.dat header=yes y=1 x=2 ycats=yes xbinsize=5 \ colorlist=white,limegreen,green,teal,blue,purple,black </pre> <p> Counting instances again. In this example X is categorical and Y is numeric, and a user-supplied x binsize and color scheme was used. Y bin size and color breakdown are automatically determined.<tt> </tt> <br><br><br> <h2>heatmap example 3</h2> <img src="../gallery/prefab_img/heatmap3.gif"> <pre> pl -prefab heatmap data=data26 x=1 xcats=yes y=2 ycats=yes contentfield=3 \ outline="color=black width=5" The data26 file looks like this: CL PNG 44 CL SVG 38 CL SWF 26 CL PS 54 CGI PNG 37 ... </pre> <p> In this example, instead of counting instances, a predetermined value (<tt>contentfield=3</tt>) is used to set cell color. Both X and Y are categorical. The cells are separated by thicker black lines.<tt> </tt> <br><br><br> <h2>heatmap example 4</h2> <img src="../gallery/prefab_img/heatmap4.gif"> <pre> pl -prefab heatmap data=data26 x=1 xcats=yes y=2 ycats=yes contentfield=3 \ symbol="shape=circle radius=0.1" legendsep=0.2 zerocolor=white </pre> <p> Same as example 3 but circles are used for cells, and background is white.<tt> </tt> <hr> <h2><a href="prefab_lines.html">lines</a></h2> <p> These examples all use <a href="prefab_lines.html"> the lines prefab.<tt> </tt> </a> All examples are included in the distribution (<tt>./pltestsuite/testpf_lines</tt>).<tt> </tt> <br><br><br> <h2>lines example 1</h2> <center><table cellpadding=2><tr> <td><img src="../gallery/prefab_img/lines1.gif"></td></tr> </table></center> <p> <pre> pl -prefab lines data=data17 x=1 y=2 pointsym=none The data17 file: 331 75 331.624 83.5518 332.105 88.7758 ..etc. </pre> <h2>lines example 2</h2> <center><table cellpadding=2><tr> <td><img src="../gallery/prefab_img/lines2.gif"></td></tr> </table></center> <p> <pre> pl -prefab lines data=data10 delim=tab x=1 y=2 y2=4 step=yes \ yrange=0 name="Group A" name2="Group B" xlbl=Months </pre> <h2>lines example 3</h2> <p> <center><table cellpadding=2><tr> <td><img src="../gallery/prefab_img/lines3.gif"></td></tr> </table></center> <p> <pre> pl -prefab lines data=data10 delim=tab x=1 y=2 err=3 y2=4 err2=5 \ y3=6 err3=7 y4=8 err4=9 yrange=0 xlbl=Months \ name="Group A" name2="Group B" name3="Group C" name4="Group D" The data10 file: 0 100 2 100 4 100 3 100 4 1.5 92 4 94 7 87 6 86 5 3 89 4 92 8 78 6 74 4 6 86 5 91 8 65 8 61 6 ..etc. </pre> <h2>lines example 4</h2> <p> <center> <img src="../gallery/prefab_img/lines4.gif"> </center> <p> <pre> pl -prefab lines data=data20 x=1 y=2 The data20 file: 1031 20.96 6.4 1032 19.71 5.8 1033 19.98 5.9 ... etc. </pre> <h2>lines example 5</h2> <p> <center> <img src="../gallery/prefab_img/lines5.gif"> </center> <p> <pre> pl -prefab lines data=data20 x=1 y=2 fill=redorange pointsym=none \ y2=2 pointsym2=none </pre> In this example the same data field was given twice, first to do the filled area, and again to do the blue line.<tt> </tt> <br><br><br> <h2>lines example 6</h2> <p> <center> <img src="../gallery/prefab_img/lines6.gif"> </center> <p> <pre> pl -prefab lines data=data20 x=1 y=2 gapmissing=yes </pre> <h2>lines example 7</h2> <p> <center> <img src="../gallery/prefab_img/lines7.gif"> </center> <p> <pre> pl -prefab lines data=data20 x=1 y=2 fill=tan1 pointsym=none \ y2=2 pointsym2=none y3=3 pointsym3=none linedet3=color=black \ yrange="0 25" name="background" name3="interior" </pre> <br><br><br> <hr> <h2><a href="prefab_multidist.html">multidist</a></h2> <p> This example uses the <a href="prefab_multidist.html"> multidist prefab.<tt> </tt> </a> <br><br><br> <h2>Example 1</h2> <p> <center><table cellpadding=2><tr> <td><img src="../gallery/prefab_img/multidist1.gif"></td></tr> </table></center> <p> <pre> pl -prefab multidist overlay=yes data=data21 rotate=yes \ xrange="0 2000" yrange="0 20" The data21 file is like this: sample1 380 239 384 384 1220 888 sample2 778 870 398 499 1472 ..etc. </pre> <p> <hr> <h2><a href="prefab_pie.html">pie</a></h2> <p> These examples use <a href="prefab_pie.html"> the pie prefab.<tt> </tt> </a> They are included in the distribution (<tt>./pltestsuite/testpf_pie</tt>).<tt> </tt> <br><br><br> <h2>pie example 1</h2> <p> <center><table cellpadding=2><tr> <td><img src="../gallery/prefab_img/pie1.gif"></td></tr> </table></center> <p> <pre> pl -prefab pie values=3 labels=1 data=data9 \ delim=tab title="Student enrollment" data9 file: Business Admin 1.39 331 English 1.67 182 Chemistry 2.07 301 ..etc. </pre> <br><br><br> <h2>pie example 2</h2> <center><table cellpadding=2><tr> <td><img src="../gallery/prefab_img/pie3.gif"></td></tr> </table></center> <p> <pre> pl -prefab pie data=data23 delim=tab values=2 labels=1 colorfld=3 \ title="Colors from data field" legend=yes the data23 file: Employment 8 red In transit 2 orange Meals 1 green Errands 1 purple Household chores 2 yellow Recreation & relaxation 2 blue Sleep 8 gray(0.8) </pre> <p> Colors driven by data, and a legend for explanation.<tt> </tt> <br><br><br> <h2>pie example 3</h2> <img src="../gallery/prefab_img/pie4.gif"> <pre> pl -prefab pie data=data23 delim=tab values=2 "labelfmtstring= @1\n (@PCT%)" colorfld=3 labelback=dullyellow firstslice=90 center="4 3" radius=1.5 </pre> Labels with backing boxes, and an explicitly defined center and radius.<tt> </tt> <hr> <h2><a href="prefab_scat.html">scat</a></h2> <p> These examples use the <a href="prefab_scat.html"> scat prefab </a> and are included in the distribution (<tt>./pltestsuite/testpf_scat</tt>).<tt> </tt> <br><br><br> <h2>scat examples 1 & 2</h2> <center><table cellpadding=2 cellspacing=8><tr> <td><img src="../gallery/prefab_img/scat1.gif"></td><td><img src="../gallery/prefab_img/scat2.gif"></td></tr> </table></center> <p> <pre> Left: pl -prefab scat data=data1 x=2 y=3 Right: pl -prefab scat data=data1 x=2 y=3 id=1 \ xlbl="Total Ch" ylbl="White Blood Cell Count" corr=yes data1 file: A/J 1.39 331 BALB/cJ 1.67 182 C3H/HeJ 2.07 301 ..etc.. </pre> <h2>scat example 3</h2> <center><table cellpadding=2><tr> <td><img src="../gallery/prefab_img/scat3.gif"></td></tr> </table></center> <pre> pl -prefab scat data=data3 x=2 y=6 err=3 xerr=7 corr=yes \ ptshape=triangle ptsize=0.08 ptcolor=red "errcolor=gray(0.8)" data3 file: 129S1/SvImJ 0.4927 0.111 0.353 129S1/SvImJ 0.4080 0.0839 0.265 A/J 0.5547 0.0768 0.243 A/J 0.6051 0.0656 0.207 AKR/J 0.4125 0.0631 0.200 AKR/J 0.3653 0.0418 0.132 ...etc. </pre> <h2>scat example 4</h2> <center><table cellpadding=2><tr> <td><img src="../gallery/prefab_img/scat4.gif"></td></tr> </table></center> Two different sets of data points are plotted using two different symbols, and error bars are also generated.<tt> </tt> The sets are selected using <tt>ptselect</tt> and <tt>ptselect2</tt>.<tt> </tt> <pre> pl -prefab scat data=data25 delim=tab x=3 y=4 err=5 ptselect=" = A" xerr=6 \ x2=3 y2=4 err2=5 ptselect2=" = B" xerr2=6 data25 file: ABC A 5 4 2.5 2.3 ABC B 4 4.5 1.6 1.8 DEF A 8 9 1.8 1.5 DEF B 3 3 0.9 1.3 GHI A 7.7 6.5 1.2 0.6 GHI B 6.6 6.3 0.8 1.1 </pre> <br><br><br> <hr> <h2><a href="prefab_stack.html">stack</a></h2> <p> These examples use the <a href="prefab_stack.html"> stack prefab.<tt> </tt> </a> They are included in the distribution (<tt>./pltestsuite/testpf_stack</tt>) <br><br><br> <h2>stack example 1 - bars</h2> <p> <center><table cellpadding=2><tr> <td><img src="../gallery/prefab_img/stack1.gif"></td></tr> </table></center> <p> <pre> pl -prefab stack data=data10 x=1 y=2 y2=4 y3=6 y4=8 xlbl=Months \ name="Group A" name2="Group B" name3="Group C" name4="Group D" data10 file: 0 100 2 100 4 100 3 100 4 1.5 92 4 94 7 87 6 86 5 3 89 4 92 8 78 6 74 4 ..etc. </pre> <h2>stack example 2 - a stacked area plot</h2> <center><table cellpadding=2><tr> <td><img src="../gallery/prefab_img/stack3.gif"></td></tr> </table></center> <p> <pre> pl -prefab stack data=data5 delim=tab x=1 y=2 y2=3 y3=4 y4=5 \ stackarea=yes echodata=yes stubvert=yes \ name=eastern name2=central name3=mountain name4=pacific data5 file looks like this: Test 4 83 12 64 9 Test 5 95 11 92 13 Test 6 42 8 76 11 Test 7 69 13 68 6 Test 8 76 19 84 14 Test 9 83 12 64 9 Test 10 95 11 92 13 Test 11 42 8 76 11 Test 12 69 13 68 6 </pre> <hr> <h2><a href="prefab_vbars.html">vbars</a></h2> <p> These examples use the <a href="prefab_vbars.html"> vbars prefab </a> and are included in the distribution (<tt>./pltestsuite/testpf_vbars</tt>) <br><br><br> <h2>vbars example 1</h2> <p> <center><table cellpadding=2><tr> <td><img src="../gallery/prefab_img/vbars1.gif"></td></tr> </table></center> <p> <pre> pl -prefab vbars data=data4 delim=tab x=1 y=2 vals=yes\ yrange=0 yinc=20 ygrid=yes barwidth=0.3 data4 file: Group A 78 7 Group B 84 12 Group C 56 6 </pre> <h2>vbars example 2</h2> <center><table cellpadding=2><tr> <td><img src="../gallery/prefab_img/vbars2.gif"></td></tr> </table></center> <p> <pre> pl -prefab vbars data=data5 delim=tab x=1 y=2 err=3 \ y2=4 err2=5 errunder=yes ygrid=yes barwidth=0.1 \ name=Treatment name2=Control stubvert=yes data5 file: Test 3 76 19 84 14 Test 4 83 12 64 9 Test 5 95 11 92 13 ...etc.. </pre> <h2>vbars example 3</h2> <center><table cellpadding=2><tr> <td><img src="../gallery/prefab_img/vbars3.gif"></td></tr> </table></center> <p> <pre> pl -prefab vbars data=data5 delim=tab x=1 y=2 err=3 y2=4 \ err2=5 erronly=yes name=Treatment name2=Control stubvert=yes \ errcolor=red errcolor2=blue sep=0.08 xgrid=yes ylog=log </pre> <h2>vbars example 4</h2> <center><table cellpadding=2><tr> <td><img src="../gallery/prefab_img/vbars4.gif"></td></tr> </table></center> <pre> pl -prefab vbars data=data18 x=1 y=2 crossover=0 \ color=blue vals=yes The data18 file: 1992 -47 1993 -63 1994 -24 1995 12 ..etc. </pre> <hr> <h2><a href="prefab_vdist.html">vdist</a></h2> <p> These examples use <a href="prefab_vdist.html"> the vdist prefab.<tt> </tt> </a> They are included in the distribution (<tt>./pltestsuite/testpf_vdist</tt>).<tt> </tt> All examples use data from the <tt>data6</tt> and <tt>data6b</tt> files having one field containing several hundred numeric values.<tt> </tt> <br><br><br> <h2>vdist example 1</h2> <p> <center><table cellpadding=2><tr> <td><img src="../gallery/prefab_img/vdist1.gif"></td></tr> </table></center> <p> <pre> pl -prefab vdist data=data6 y=1 </pre> <br><br><br> <h2>vdist example 2</h2> <center><table cellpadding=2><tr> <td><img src="../gallery/prefab_img/vdist2.gif"></td></tr> </table></center> <p> <pre> pl -prefab vdist data=data6 y=1 mediansym=dot dist=hist \ showoutliers=yes </pre> <br><br><br> <h2>vdist example 3</h2> <center><table cellpadding=2><tr> <td><img src="../gallery/prefab_img/vdist3.gif"></td></tr> </table></center> <p> <pre> pl -prefab vdist data=data6 data2=data6b y=1 y2=1 dist=hist \ title="Set 1" title2="Set 2" </pre> <p><hr> Markup created by <em>unroff</em> 1.0, <tt> </tt> <tt> </tt>March 11, 2009. </body> </html>