chemdata:digitizer

Mass Spectrum Digitizer Program

Written by Meng Zhai Chemical and Biomolecular Measurement Division, National Institute of Standards and Technology (NIST), Gaithersburg, Maryland

For inquiries regarding this program please contact Dr. David Sparkman at odspark@gmail.com.

Download the program here (1/8/2010).

Short tutorial

The following is a tutorial on how to digitize a mass spectrometry spectrum using the Spectrum Digitizer program. There are step-by-step instructions on how to go from an image to a .msp file containing the desired information.

image of spectrumdigitized spectum

Obtaining the data

  1. Opening a spectrum
    1. Click on the Open button.
    2. Find your image.You will only be allowed to choose images of the supported file types (.jpg, .bmp, .gif, .png).
    3. Click on the Open button in the file chooser box. Your image should now appear.
  2. Resizing the image
    1. After you open an image, you can press the + or - buttons to zoom in and out on the image. Press the Unzoom button to set the image to its original size.
    2. After you are satisfied with the size of your image, press the Done button to continue.
    3. If you want to go and and change the zoom on your image, press the Reset button (originally where the Done button was located).
  3. Adding X calibration values
    1. You will need to give the program some calibration points for it to work. The textbox at the top right corner should say “Set X”.
    2. The red cross-hairs should follow your mouse. Move your mouse until the vertical red line is lined up with an X value that you know the real value of, and click to set that value.
    3. The “Image X:” value should change as you move your mouse. This is the pixel value of the X value you click on. Once you clicked your mouse, the textbox next to “Real X:” is highlighted. This is where you should enter in the actual X value you have just selected.
    4. Once you have the correct pixel and real values for the X value you have just selected, click on the Add button, or press the Enter key on the keyboard.
    5. The pixel and real value should be added to the calibration list. You can add as many X calibration values as you want, but you need to have at least two points. Calibration points are always added to the list in the format: pixel value, real value.
    6. The program automatically waits for you to click on the next pixel value, so repeat steps 1-5 until you have the desired number of X calibration values.
    7. If at any time you need to add more X calibration values, click on the Set X button, and then start at step 1.
  4. Deleting X calibration values
    1. You can also delete calibration values. Select the points you want to delete. (You can select multiple values by using shift and control.)
    2. Click on the Delete button. Remember, you need at least two calibration points to proceed.
  5. Calibrating Y0
    1. You will need to also calibrate the Y values by setting two points, the minimum and the maximum. To set the minimum, click on the Set Y0 button.
    2. The textbox at the top right corner should say “Set Y0”.
    3. Move your mouse until the horizontal red line is lined up with the X axis (where Y is 0), and click to set that value.
    4. The “Image Y0:” value should change as you move your mouse. This is the pixel value of the Y value you click on. The “Real Y0:” value is set to 0 by default, and it is not recommended that you change this value.
  6. Calibrating Y1
    1. You will need to input the maximum, Y1. Click on the Set Y1 button.
    2. The textbox at the top right corner should say “Set Y1”.
    3. Move your mouse until the horizontal red line is lined up with the top of the highest peak on the spectrum (the maximum Y value), and click to set that value.
    4. The “Image Y1:” value should change as you move your mouse. This is the pixel value of the Y value you click on. The “Real Y1:” value is set to 9999 by default, and it is not recommended that you change this value.
  7. Setting the boundaries and getting the data
    1. You will also need to set boundaries on your spectrum. Click on the Left button.
    2. The textbox at the top right corner should say “Set Left Bound”. (When you set the right bound and the threshold, the text in the box should change accordingly.)
    3. Move your mouse until the vertical red line is where you want the left boundary to be, and click to set the boundary. The program will not get any data to the left of this line.
    4. You will also need to set the right boundary. Click on the Right button.
    5. Move your mouse until the vertical red line is where you want the right boundary to be, and click to set the boundary. The program will not get any data to the right of this line.
    6. You will also need to set the X threshold. The program will not get any data that has peaks below this line. Click on the Threshold button.
    7. Move your mouse until the horizontal red line is where you want the threshold line to be, and click to set the threshold. Make sure the line goes through all the peaks you want and above any peaks you don't want, since the program will not get any data that has peaks below this line.
    8. When you are satisfied with the three boundaries you set and all your calibration values, click on Set Points to get the data.
  8. Viewing the data
    1. After click on Set Points, if there had been no errors, a list of all the data points of real values, in the format x,y, should appear in the list in the bottom right hand corner. Pink and green points should also be drawn on the peaks in the spectrum image. Each of the points drawn corresponds to a point in the list.

Manually manipulating the data

  1. Moving points
    1. Click on a data point in the list to select it. Then, use the arrow keys on the keyboard to move it around.
    2. Alternatively, click on the point you wish to select on the spectrum image, and drag the mouse to move it.
    3. The point that is being moved should change coordinates in the list as you move it.
  2. Adding points
    1. Click on the Add button.
    2. Click on the spectrum image where you wish to add the point.
    3. The new point should appear in the list in the correct, sorted position.
  3. Deleting points
    1. Click on the point you wish to select on the spectrum image to delete.
    2. The point you selected should also be highlighted in the list.
    3. Alternatively, you can select the point you wish to delete by clicking on the data point in the list.
    4. Click on the Delete button.

Exporting the data

You can enter in information about the molecule/spectrum in textboxes at the top.

  1. Entering identification information
    1. Name: Name of the molecule.
    2. Formula: The molecular formula of the molecule.
    3. MW: The molecular weight of the molecule.
    4. Contributor: The author, title, volume/issue, pages, etc. of the journal article that had the spectrum, or the source of the spectrum.
    5. CASNO: The unique CAS (Chemical Abstracts Service) registry number assigned to this molecule.
    6. Date: The date this spectrum is digitized (should appear automatically).
    7. Digitizer: The user who digitized this spectrum (should appear automatically).
  2. Saving as a .msp file
    1. Click on the Save button.
    2. Find the folder in which you want to save the text file. Type the name you want the text file to be saved as. You can choose to add .msp to the end of the filename, but you do not have to. The .msp extension will be added automatically.
    3. Click on the Save button in the file chooser box.
    4. If you select a preexisting file, you have the option of overwriting the file or appending the current list with its identification information onto the old file.
    5. .msp is the default format of the data entered into NIST's Mass Spectral Database. Please inquire for details.

Using keyboard shortcut keys

:!: Note: Shortcut keys can only be used if a textbox is not selected. To deselect, click anywhere on the image or the black space.

  1. Shortcuts available at all times
    • - (Minus sign) - Zoom out
    • + (Plus sign) - Zoom in
    • 0 - Unzoom
    • - Space-bar - Done
  2. Shortcuts available when zooming
    • - (Minus sign) - Zoom out
    • + (Plus sign) - Zoom in
    • 0 - Unzoom
    • Space-bar - Done
  3. Shortcuts available when calibrating
    • O - Reset to zoom
    • S - Set X
    • A - Add (the Enter key can also be used)
    • W - Highlight Real X textbox
    • Control, Shift - Select multiple calibration points
    • D - Delete selected calibration points
    • F - Set Y0
    • G - Highlight Real Y0 textbox
    • R - Set Y1
    • T - Highlight Real Y1 textbox
    • Z - Left
    • C - Right
    • X - Threshold
    • Space-bar - Set Points
  4. Shortcuts available when manipulating points
    • O - Reset to zoom
    • P - Reset to calibration
    • Page Up - Select previous point on list
    • Page Down - Select next point on list
    • Control, Shift - Select multiple data points
    • Insert - Add
    • Delete - Delete
    • Arrow Keys - Move a data point

Possible errors

1. Invalid calibration input You did not enter an integer for one of the calibration inputs (Image/Real X, Y0, Y1). No decimals, letters, other characters, etc. are allowed.

2. Boundaries out of bounds One of the boundary lines is out of bounds. One of the following is happening:

  • The left bound is farther left than the left side of the image.
  • The right bound is farther right than the right side of the image.
  • The left bound is to the right of the right bound. (The right bound is to the left of the left bound.)
  • The threshold line is below the image.
  • The threshold line is above the image.

3. At least two X values required You can enter in as many X calibration values as you want, but you need to enter in at least two uniqe ones.

4. Calibration points repeated You cannot have any repeated calibration points. You must enter in at least two unique calibration values for X.

5. Please remove duplicate The final list of x, y values that is save is not allowed to have pairs that share the same X value. Delete or change the duplicate pairs at the X value shown.

chemdata/digitizer.txt · Last modified: 2016/09/19 09:56 (external edit)

Page Tools