Events News Research CBS CBS Publications Bioinformatics
Staff Contact About Internal CBS CBS Other

Making Figures

xmgrace (the new version of xmgr) is probably the best plotting program on our unix system (another option is gnuplot)
grep -v ^# /usr/opt/www/pub/CBS/researchgroups/immunology/intro/Figures/pred.dat | gawk '{print $3,$4}' | xmgrace -pipe Piping data to xmgr. The input file(s) may also be given on the command line
grep -v ^# /usr/opt/www/pub/CBS/researchgroups/immunology/intro/Figures/pred.dat | gawk '{print $3,$4}' >plot.dat Piping data to file
xmgrace plot.dat

Double click on the middle of the plot to select plot style (chose for example red filled squares, no lines!)
Double click on the axes to add axis labels
Double click on the top of the plot to add title for plot
Chose "File>Save" to save plot
Chose "File>Print setup", choose Device:"EPS", Output:"Print to file", set File name to "plot.eps", Size:"A4", and press accept.
Chose "File>Print" to print to the file

View the file: xpsview plot.eps

Postscript hacking
poscript files are text files and can be "hacked/edited" manually or by programs; Try to find "Times-Roman" in the file and change it to "Helvetica-Bold" and view it again.

You can print a text file or a postscript file by the command lp lp plot.eps To print it on the color printer: lp -dhpcol plot.eps

Transforming figures to png or tiff format
Word imports postscript figures in a low resolution so it is better to do it yourself. This can be done using the gimp program. A resolution of 300 is normally fine for publications. Jpeg format gives smaller files but is not good for figures which often have sharp edges. Tiff is another good option which is prefered by some publishers.

Example of converting postscript file to png format
Use: ssh -X life gimp plot.eps
If his does not work (plot.eps can not be found)try: ssh -X life
cd directory_where_your_figure_file_is
gimp plot.eps
Choose resolution 300
(Increase hight-width if all of figure is not included)
Right click on figure and select
File>Save As>
Change extension to .png (or tiff)

Importing figures to word/powerpoint
Chose "Insert>Picture>From File", and select the file.

You can also make plots using Excel on your PC. You can save your data in a tab separated file (Can be made using the printf command in awk/perl/c, e.g. printf("%f\t%f\n", a, b)) and give it the extension ".xls". Then it can be opened by exel by double clicking on it.