Biotech > FAQ > RasMol and Chime FAQ (Frequently Asked Questions)

Gzipping PDB files for Chime

To see other biotech frequently asked questions, please visit

(Continued from previous question...)

Gzipping PDB files for Chime

You can skip this (rather technical) section unless you are putting a Chime-based presentation on a web server.

All PDB files placed on servers for use by Chime should be gzipped. (Note, however, that if the same copy of the file is to be used for RasMol, it should not be gzipped since only unix-RasMol can understand gzipped PDB files -- RasWin and RasMac cannot!)

Chime will automatically decompress and display PDB files compressed with the gzip method. Such compression reduces the sizes of PDB files by about 3.5-fold, and reduces the time required to transfer the files through the Internet by a similar amount. When Chime's "File, Save Molecule As" menu option is used, the file will be saved decompressed (as plain text), even if Chime received the file gzipped.

Gzip is a freeware program available for a wide variety of computer platforms. Gzip originates from the Free Software Foundation, but they do not provide the application program directly. To download gzip, see the paragraph below for Windows or Macintosh.

Gzipping on Windows: Download gzip.exe (which is also available on most shareware/freeware web sites). To gzip, for example, 1d66.pdb, open a DOS window, and type the command "gzip 1d66.pdb". This will produce the file 1d66.pdz which you should probably rename to 1d66.pdb (see below).
To decompress a gzipped PDB file: If you run gzip with no parameters, just "gzip", it will reply "For help, type: gzip -h". From the help, you will learn that to decompress a file, the command is "gzip -d <filename>". However, the filename must end in "z", so before decompressing, you'll need to rename, for example, 1d66.pdb back to 1d66.pdz. Then after you "gzip -d 1d66.pdz" it will produce 1d66.pd, which you'll have to rename back to 1d66.pdb.

Gzipping on Macintosh: The source of the application is MacGzip Home Page (Spain).

Serving gzipped PDB files: In most cases, after gzipping a PDB file for use on a web server, you will need to rename the gzipped file back to a name ending in .pdb. This is because typically the server will be configured to serve files ending in .pdb as MIME type chemical/x-pdb, which directs the browser to hand these files to the Chime plug-in for display. Unless you can get the server administrator to reconfigure the server to serve other types of files (for example ending .pdb.gz or .pdz) as chemical/x-pdb, other file types won't be displayed in Chime.

If using ftp to transfer the gzipped PDB file to the server, make sure you force binary mode! Although unzipped PDB files are plain ASCII text, transferring a gzipped file in ASCII mode will corrupt it. Test your gzipped PDB files by viewing in Chime from the server after transferring them!

(Continued on next question...)

Other Frequently Asked Questions