[Keynote], [Mac OS X Softwares], [Setting up Mac]

How to make PAW plots for presentations

If you simply use default settings for PAW to create plots and import them to Keynote slides, the lines are too thin, and characters are too small. Here are some examples to solve the problem.

Preparations

  1. Under your home directory, create a directory ~/kumacs .
  2. Inside ~/kumacs , place the follwoing two files. Hold CTRL-key while pressing the mouse key, and select "Save Linked File ..." to download them.
  3. Under your home directory, create or edit ~/.pawlogon.kumac and insert the following line.
    	defaults -auto '.,~/kumacs/'
    				
    This way, kumac commands in the current directory and ~/kumacs/ will be available at any directory.
  4. If you do not have PAW (that comes with CERNLIB), use Fink to install it. (Japanese instructions)

Creating plots

  1. Launch PAW, and display the plots that you want to include in your slides.
  2. Here is an example PAW session.
    	PAW > h/file 1 foo.hbook
    	PAW > mplot
    	PAW > h/plot 100
    	PAW > fort/file 22 foo.ps
    	PAW > meta 22 -111
    	PAW > h/plot 100
    	PAW > meta 0
    	PAW > close 22
    				
    If you use lplot instead, the output will be more suitable for large plots filling the entire slide.
  3. If the Postscript file (foo.ps, for example) only has one plot, simply drag the file to your Keynote slide.
  4. If the Postscript file has multiple plots, open it with Preview application, select a dotted-box tool on the top-right, and select the plot you need, and do Edit>Copy. Switch to Keynote (by control-tab), and do Edit>Paste.
  5. For further tuning, use HELP in PAW or read PAW User's Guide.

Editing Postscript files

In some cases, you only have a PS file but you cannot use PAW to recreate it. One easy way out of this is to edit the PS file.

  1. Use your favorite editor like vi or emacs, and open the PS file.
  2. Inside, you will see a line like the following.
    /c {setrgbcolor} def /lw {setlinewidth} def /sd {setdash} def
    				
    The "/lw {setlinewidth} def" is defining a new command called "lw", which simply does "setlinewidth". Leave this as it is.
  3. Next, you will find lines like the following.
     1 1 Zone
     gsave 0 0 t black [] 0 sd 1 lw 2223 2224 0 460 bl 2223 2224 0 460 C NC 1779
    				
    Notice "1 lw" burried in the line? This sets the line width (lw = setlinewidth command) to "1". Postscript is written in a Reverse Polish Notation (RPN), just like good old HP calculators. You push arguments into a stack, and then following operator will retrieve the arguments from the stack does its job.
  4. Anyway, change the number BEFORE "lw" to a larger number, for example, as "6 lw". The larger the number is, the thicker the line will be. Here is an example with "6 lw".

2005-07-09 Taku Yamanaka