Week 12: Comparing Geospatial Tools

top of page

Exploring Ocean Data with ImageJ

This week's investigation integrates all three Eyes in the Sky toolsImageJ, AEJEE & ArcGIS, and Google Earthto study the migration of sea turtles. We'll start out by visiting a familiar data provider, the NASA Earth Observations (NEO) Web site, to download images of global Sea Surface Temperature and Chlorophyll Concentration. Later, you'll use other Eyes in the Sky tools to see if the sea turtle migrations are related to these data in any way.

top of page

ALERTbefore you begin


IMPORTANTA bug in ImageJ prior to version 1.43p prevents you from entering negative calibration values. Before you begin working with ImageJ, please update your copy of ImageJ to the current version (1.43u). To update ImageJ, choose Help > Update ImageJ and click OK in the updater dialog box. ImageJ will download and install the update, then quit. Re-launch ImageJ to run the new version.

Windows Vista and Windows 7 usersImageJ's built-in update function only works if you install ImageJ in the Documents directory, instead of the Programs directory. If you are unable to update ImageJ, you will need to re-install the program according to these guidelines.


nasa_neo_home top of page

Download MODIS sea surface temperature (SST) data from NEO


  1. Click here to go to the NEO Web site.
  2. In NEO, below the map, click the Ocean tab.
  3. In the Ocean Datasets list, choose the Sea Surface Temperature (MODIS) dataset.
  4. Click the dark blue About this dataset link and read more about the MODIS Sea Surface Temperature images.
  5. Close the About this dataset window when you finish reading the description.
  6. Scroll down the page until you see the Next button at the bottom of the Search Results box. Click the Next button to display the next group of images.
  7. Click the + box in front of the September 1, 2008 to October 1, 2008 result to expand it.
  8. Click the View link.
  9. In the Download Options box:
    • Change the Full option to Resize.
    • Set the image format to GeoTIFF
    • Select a fixed resolution of 0.25 degrees per pixel.
    • Click the Get Image button to download the file. It will download to the default download location.
If you have difficulty downloading the September 2008 SST image file from NEO, download and use this one instead. Right-click (Win) or control-click (Mac) the link below and download it to your Week 12 folder or directory:

September 2008 SST GeoTIFF (TIFF 1020kB May7 10)

top of page

Density calibration in ImageJ


Earlier in the course, you learned how to spatially calibrate an image. In a spatially calibrated image, distances and areas in pixels are converted to real-world units of measure, like kilometers and square kilometers.

This week, you'll learn how to density calibrate an image. In density calibrated images, pixel values are converted to real world measures such as reflectance, temperature, Dobson units, or whatever the detector was designed to measure.

  1. Launch ImageJ by double-clicking its icon ImageJ Icon Small on your desktop or by clicking its icon in the dock (Mac) or Launch Bar (Win).
  2. Open the September 2008 Sea Surface Temperature (SST) image you downloaded in ImageJ. It should look like this.
  3. Move your cursor around over the image, looking at the pixel values in different areas. What pixel value represents land? What value represents missing data?

top of page

Where do calibration values come from?


To density calibrate a digital image, you need to have at least two known measurements and their corresponding pixel values. You also need to know the mathematical relationship between the twois it linear? polynomial? exponential? With sea surface temperature, this translates into "What do you have to do, mathematically, to change a pixel value into a temperature value?" You also need to know the units of measure. Is the temperature reported in degrees Fahrenheit or degrees Celsius?

In a perfect world, this information would always be provided in a standard format. However, in the real world, you need to get the calibration information any way you can. The information is out there somewhere, but you can't always easily find it. Don't let that stop you from trying!

In this case, we will look at the legend below the preview image in the NEO interface. For the SST images, it's always the same, and looks like this:

Note that the units are degrees Celsius, and only two values are shown. The minimum temperature is -2 degrees and the maximum temperature is 45 degrees. Since only two values are shown, we are going to assume that the relationship between pixel values and degrees Celsius is linear. That means that we can change pixel values to degrees by simply multiplying the pixel value by a constant and adding another constant.

We'll assume that the lowest possible pixel value represents the lowest possible temperature, so a pixel with a value of 0 represents a temperature of -2 degrees Celsius.

We'll also assume that the highest possible pixel value (except for the Land / No Data value of 255) represents the highest possible temperature. In other words, a pixel value of 254 represents a temperature of 45 degrees Celsius.

Calibration information can also be provided by a mathematical formula or through descriptive text. In an image where pixel value represents elevation, you might get your calibration informationthe elevations of two known locations in the scenefrom Google Earth or a topographic map. Like spatial calibration, density calibration often involves a lot of detective work and intuition or "educated guessing."


Now you will use this information to calibrate the SST image.

  1. In ImageJ, choose Analyze > Calibrate.
  2. In the Calibrate dialog box, the left column is for entering pixel values and the right column is for entering the calibrated values or known measurements.
  3. Set up the Calibrate dialog box as follows:
    • In the left column, enter 0 (zero), press return, then enter 254.
    • In the right column, enter -2, press return, then enter 45.
    • For the units, enter C or Degrees Celsius.
    • From the Function menu, choose Straight Line
    • Click OK. A Calibration Function window appears.
  4. Close the Calibration Function window.
  5. The image is now density calibrated! Mouse around the image, reading the calibrated values from ImageJ status bar.
  6. Save your calibrated September 2008 SST image to your Week 12 folder as a .tif image. (You do NOT need to post this image to your discussion group.)
  7. In case you have trouble with the calibration process, here's a calibrated version of the September 2008 SST file to download open and look at in ImageJ. Calibrated Sept 2008 SST (TIFF 1014kB May8 10)

top of page

Analyzing Density Calibrated Images in ImageJ


Now that you have a calibrated image, let's take a brief look at some of the tools provided by ImageJ to analyze the image.


Choosing which measurements to make


Before starting any analysis in ImageJ, you need to choose which measurements you will make.

  1. Choose Analyze > Set Measurements to open the Set Measurements window.
  2. Turn on the following measurements: (Turn off the others.)
    • Area
    • Standard Deviation
    • Min & Max Gray Value
    • Mean Gray Value
    • Modal Gray Value
    • Median
  3. Close the Set Measurements window.

top of page

Making simple measurements


  1. Use any of ImageJ's selection toolsrectangle, ellipse, polygon, freehand area, or lineto select a region to measure. We used the Freehand Area selection tool to select part of the Indian Ocean.
  2. Choose Analyze > Measure.
  3. ImageJ will display the measurement results in the Results window. Distances and areas are in pixels and square pixels, other measurements are in degrees Celsius.
  4. Close the Results window. Don't save your measurements.
  5. Choose Edit > Selection > Select None to remove the selection you made.

top of page



A quick way to analyze all of the data in an image is to create a histogram. A histogram is a graph that shows the frequency (the number of pixels) of each value. The Histogram window also includes basic statistical values, such as mean, median, and modein calibrated units, if the image has been density calibrated.

  1. Choose Analyze > Histogram.
    Unfortunately, the statistics for the whole image are skewed by the large number of black (land or no data) pixels. To get around this, you can also create a histogram from the pixels in a selected area.
  2. Here's another handy trick. To restore the most recent selection (in this case, the one you removed at the end of the previous section), choose Edit > Selection > Restore Selection.
  3. Choose Analyze > Histogram again.
    You can see that the histogram and statistics now reflect only the data in the selected area.
  4. Close the Histogram window.

top of page

A related techniquesaving a region of interest (ROI)


What if we wanted to measure exactly the same area (called a Region of Interest, or ROI) on many images, especially on different days. You can save a selection as a region of interest (.roi) file in ImageJ.

  1. Use any of the selection tools to make a selection (a ROI) on the image.
  2. Choose File > Save As > Selection and save the file with an appropriate name into your Week 12 folder or directory.
  3. Use a selection tool to make a different selection on the image. You could restore your previous selection, but what if you needed to restore a selection you made two months ago?

  4. Choose File > Open and navigate to the .roi file you saved and open it. Your saved selection should be restored. This technique is invaluable for making identical measurements over long periods of times, with different students, and many images. 

top of page

Creating density profile plots


A density profile plot shows how a quantity varies along a path.

  1. Use the Straight Line Selection tool to make a roughly north-south line selection through an ocean.
  2. Choose Analyze > Plot Profile. A profile plot window will open.
  3. Close the profile plot window.
CautionDensity profile plots can be misleading! A density profile plot shows changes in whatever quantity the pixels represent. If the pixels represent elevation, the density profile represents a topographic profile. However, if the pixel values represent temperature, the density profile is a temperature profile. A profile plot across an uncalibrated satellite image gives you a relative brightness profile. A common error is making a density profile across a satellite image of the Grand Canyon and assuming that the plot represents the topography of the canyon. You have been warned!


top of page

Add a calibration bar to an image


Earlier in this course, you learned how to spatially calibrate and add a scale bar to an image. You can also add a density calibration bar, or legend, to an image.

  1. Cancel your line selection.
  2. Choose Analyze > Tools > Calibration Bar.
  3. ImageJ creates a copy of the current image window and opens the Calibration Bar dialog box. In the Calibration Bar dialog box, enter your settings. Feel free to experiment. As long as you don't click the OK button, you can change any of the calibration bar properties.
  4. When you are satisfied with the settings, click the OK button.
Note: To density calibrate an image, it must be an 8-bit color or grayscale image. Notice that the new image with the calibration bar is an RGB color image. The moral of this story? You can density calibrate an image or you can print a calibration bar on it, but you can't have both at the same timeat least not this way!

top of page

Calibrating non-linear values in ImageJ


This section is kind of a test to see if you can apply what you've learned on this page, but with a new wrinkle. Your task is to locate and download the September 2008 MODIS Chlorophyll Concentration image in NEO, then to density calibrate it. The new wrinkle is that the range of Chlorophyll Concentration values is so broadranging from about 0.015 milligrams per cubic meter (mg/m3) to around 64 mg/m3that a linear calibration would not show much color variation on the map.

  1. Using the NEO data tool, follow the same steps you used to locate and preview the SST image to find and preview the September 2008 MODIS Chlorophyll Concentration image.
  2. Download the chlorophyll image from NEO as a GeoTIFF, at 0.25 degrees per pixel (1440 x 720).
  3. If you have trouble downloading the image, here it is. September 2008 Chlorophyll (TIFF 1020kB May8 10)
  4. Open the chlorophyll image in ImageJ.
  5. Mouse over the land and no data areas and note that these pixels have a value of 255.
  6. Choose Analyze > Calibrate and enter the calibration values: (Remember, the list of pixel values goes on the left, and the list of corresponding calibration values goes in the right column.)
    • 0 = 0.015
    • 254 = 64
    • Function = Exponential
    • Unit = mg/m3
  7. Click OK to calibrate the image.
  8. Close the Calibration Function window.
  9. Mouse around the image and read the calibrated values.
  10. If you have time, practice making a few measurements on the density calibrated image.

top of page

Stacking Images for Quick Comparisons


These SST and Chlorophyll images have different color lookup tables and are calibrated differently. If you stack them the way they are now, both images will be assigned the LUT of the first image in the stack. (In other words, the Chlorophyll image will look lousy.) To stack these images, you first need to convert them to a common formatRGB color.

  1. If necessary, use ImageJ to open the calibrated September 2008 SST image and the calibrated September 2008 Chlorophyll images that you saved to your Week 12 folder or directory.
  2. Activate the SST image and choose Image > Type > RGB Color.
  3. Repeat this process to convert the Chlorophyll image to RGB Color.
  4. Choose Image > Stacks > Images to Stack.
  5. If you have trouble creating the stack, here it is. Sept 2008 SST+Chloro Stack (TIFF 5.9MB May8 10)
  6. Use the right and left arrow keys to flip back and forth through the two-slice stack.

top of page

Exploring Time Series Images With Stacks


Remember from earlier in the course that ImageJ is also useful for examining and animating a series of images that show change over time.


Sea surface temperature stack


  1. Download the following SST time series stack and open it in ImageJ. SST_Stack (TIFF 4MB May8 10)
  2. This stack represents global sea surface temperatures from September through December of 2008.
  3. Use the right and left arrow keys to flip forward and backward through the stack.

top of page

Chlorophyll stack


  1. Download the following Chlorophyll time series stack and open it in ImageJ. Chlorophyll_Stack (TIFF 4MB May8 10)
  2. This stack represents global chlorophyll concentrations from September through December of 2008.
  3. Use the right and left arrow keys to flip forward and backward through the stack.

top of page

Merging stacks


If your computer has enough memory, here's one last trick you can try...

  1. Open both the SST and Chlorophyll time series stacks.
  2. Activate each stack window and choose Image > Type > RGB Color to convert both stacks to RGB Color format.
  3. Choose Image > Stacks > Tools > Combine... to create a new stack that shows the SST and Chlorophyll images together in the same window. (Try this both with and without checking the Combine Vertically option.)
  4. Use the right and left arrow keys to flip forward and backward through the stack.

While you can add these images as layers to AEJEE, ArcGIS, and Google Earth and can turn the layers on and off to see the changes in SST, these tools generally don't change the images as smoothly as you can with an ImageJ stack.

top of page



top of page