|Search Locate Previous||Contents|
Now we can have another go at the Playfair data, and produce something very close to the 1786 original. This is actually quite a hard graphic to draw, as it has irregularly-spaced X-ticks, vertically aligned notes, and the axis is at the wrong side. Few commercial graphics tools come close, and yet you will find that the combined power of APL and Rain handle the challenge with some aplomb!
Here is the APL code to draw this ...
rPlayfair;mat © Copy of classic Playfair chart from 1786 mat2 10½1688 1701 1714 1727 1739 1748 1755 1762 1775 1784,0.2 1.3 3.2 2.4 2.1 3 2.2 4.8 4.4 9.2 ch.New 0 0 432 300 ch.Set('style' 'XYPLOT,ROWS,BOXED,NOMARK,SURFACE,GRID')('VMAR' 12 24)('HMAR' 36 24) ch.Set'Ystyle' 'RIGHT' ch.Set('Hfont' 'GAI,12')('Lfont' 'GA') ch.Set('Grid' 'solid,fine,NEUTRAL')('Datum' 'medium,solid,neutral') ch.Set('XTICK'(mat[1;]))('YRANGE' 0 20)('YTICK' 1) ch.Set('WIDTH' 'MEDIUM')('PATTERN' 1) ch.Set'HEAD' 'Interest of the NATIONAL DEBT from the Revolution' ch.Set('YDATUM' 10) ch.Plot mat © Now annotate it ... ch.Set'Nfont' 'ne,GABI,12' ch.Note'INTEREST OF NATIONAL DEBT.'(1720 0.6) ch.Set'Nfont' 'GAI,9' ch.Note'The Bottom Line is Years, those on the Right Hand Millions of Pounds'(1710 ¯2.5) ch.Set('Nfont' 'GAI,6,red')('nstyle' 'opaque') mat[2;]+0.5 ª mat[1;]-0.5 ª mat®90 ch.Note'Revolution'(mat[;1]) ch.Note'Accession of Queen Anne'(mat[;2]) ch.Note'Accession of George 1st'(mat[;3]) ch.Note'Accession of George 2nd'(mat[;4]) ch.Note'Beginning of Spanish War'(mat[;5]) ch.Note'End of Spanish War'(mat[;6]) ch.Note'Beginning of Continental War'(mat[;7]) ch.Note'End of Continental War'(mat[;8]) ch.Note'Beginning of American War'(mat[;9]) ch.Note'End of American War'(mat[;10]) PGch.Close r'View PG © to see it'
Note the use of Garamond Italic for the titles and notes. You should refer to Setting up Custom Fonts for more information on adding your favourite PostScript and TrueType fonts to the available list.