cgm format > XY files?

mathog at seqaxp.bio.caltech.edu mathog at seqaxp.bio.caltech.edu
Fri Dec 19 12:01:42 EST 1997


In article <349949AA.57C6 at infobiogen.fr>, PA Curmi <curmi at infobiogen.fr> writes:
>Hi everybody,
>
>I have files coded in "computer graphic metafile" format (cgm) which
>contain curves obtained from a spectrophotometer.
>
>It seems that this cgm format is a graphic format but that must contain
>the XY informations to plot the data.
>
>I would like to extract the XY datavalues from the cgm files and save
>it in a format which could be read by Exel or any spreadsheet program or
>plotter? 
>
>Could someone help me?
>

There are a couple of types of CGM file, one form is plain text, so you 
should first check to see if you have that.  If you do, use an editor to
yank out the data you want.

Failing that, there is a package called RALCGM which reads and displays or
converts CGM files.  It will convert a binary CGM to text CGM (or
postscript, or HPGL.)  It works on Unix, OpenVMS, and, I think, Windows
(not sure with which compiler or windows version.)  My copy came from:

  ftp//ftp.cc.rl.ac.uk/pub/graphics/ralcgm/unix/ralcgm-3.50.tar.Z

The conversion command would be something like:

  RALCGM original.cgm -t CLEAR.TXT

Of course, if all you want to do is see what the data looks like, instead 
do:

 RALCGM -d ps original.cgm  plot.ps

and send that to your postscript printer.

CGM is a very common graphics format, and it might be worth your time to 
try reading one of these files in with whatever software you have laying
about (graphics, spreadsheet, word processor...) to see if any of them
will then let you export to a better (for your purposes) file format. 

Regards,

David Mathog
mathog at seqaxp.bio.caltech.edu
Manager, sequence analysis facility, biology division, Caltech 
**************************************************************************
*   Affordable VMS? See:  http://seqaxp.bio.caltech.edu/www/pcvms.html   *
**************************************************************************




More information about the Bio-soft mailing list