Finding dimensions of a bounding box in Jmol

The Jmol applet (or Java application) is widely used to visualize the structure of molecules.  It is very powerful, but not that well documented. If you don’t have Jmol running, open the page for Glucose Oxidase (1CF3) from the Protein Databank so you can follow the instructions for finding the size of the bounding box. Right-click on the applet to get a pop-up menu with lots of options.  Under the Style submenu, click on Boundbox to show a bounding box around the molecule:

Show bounding box
Show bounding box

It would be great to know the dimensions of the bounding box, but you can’t access this information from the GUI.  Right-click again and choose Console from the menu:

Show console
Show console

On the command line, type the command

getProperty boundBoxInfo

You will see the following output:

Console output
Console output

The first line is the (x,y,z) coordinates of the center of the box.  The second line is the vector from the center of the box to one corner.  To get the dimensions of the box, multiply each component of the vector by two.  You can also get the dimensions of the bounding box by subtracting the coordinates of Corner 0 from the coordinates of Corner 1.  The International Union of Crystallography has an excellent quick-reference guide to Jmol commands.

Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s