7. Scatter Plot

The window Scatter plot displays pixel values for two raster bands as points in the 2D space. Scatter plots are useful for assessing ROI separability between two bands.


Scatter Plot

The functions are described in detail in the following paragraphs, using these conventions:

input_date = Input date

input_text = Input text

input_list = List

input_number = Input number

optional = Optional

project_save = Configuration stored in the active project of QGIS

registry_save = Configuration stored in QGIS registry

input_slider = Slider

input_table = Table

7.1. Scatter list

  • input_table Scatter list:
    • S: checkbox field; if checked, the spectral signature is displayed in the plot;
    • MC ID: signature Macroclass ID;
    • MC Info: signature Macroclass Information;
    • C ID: signature Class ID;
    • C Info: signature Class Information;
    • Color: color field; double click to select a color for the plot;
  • Band X input_number: X band of the plot;

  • Band Y input_number: Y band of the plot;

  • checkbox Precision input_list: use custom precision for calculation (precision should be selected according to pixel values):
    • 4 = \(10^{-4}\)
    • 3 = \(10^{-3}\)
    • 2 = \(10^{-2}\)
    • 1 = \(10^{-1}\)
    • 0 = 1
    • -1 = 10
    • -2 = \(10^{2}\)
    • -3 = \(10^{3}\)
  • Calculate enter: calculate the scatter plot for the ROIs checked in the list;

  • remove: remove highlighted signatures from this list;

  • scatter_raster_temp_ROI: add a temporary scatter plot to the list (as MC Info = tempScatter) and start the plot calculation of the last temporary ROI (see Working toolbar);

  • scatter_raster_display: add a temporary scatter plot to the list (as MC Info = tempScatter) and start the plot calculation of pixels in current display extent;

  • scatter_raster_image: add a temporary scatter plot to the list (as MC Info = tempScatter) and start the plot calculation of the entire image;

    WARNING: Using a precision value that is too high can result in slow calculation or failure.

7.1.1. Scatter raster

This tool allows for the drawing of selection polygons inside the scatter plot; these selection polygons are used for creating a Scatter raster that is a temporary raster classified according to the intersection of scatter plots and drawn polygons.

Pixels of the Input image are classified, according to scatter plot bands, if pixel values are in the range of intersection between scatter plots and selection polygons (polygons should not overlap). The value assigned to the Scatter raster pixels is the sequential number of selection polygon; also the raster color is derived from the selection polygon.

After the creation of a new Scatter raster, old rasters are placed in QGIS Layers inside a layer group named Class_temp_group (custom name can be defined in Temporary group name) and are deleted when the QGIS session is closed.

  • scatter_edit_polygon: activate the cursor for interactively drawing a polygon in the plot; left click on the plot to define the vertices and right click to define the last vertex closing the polygon;
  • color: select the color of polygon (which is used also in the Scatter raster);
  • scatter_reset_polygon: remove all the selection polygons from the plot;
  • scatter_show_raster: calculate the Scatter raster and display it in the map;
  • save_plot: calculate the spectral signature of the Scatter raster (considering all the classified pixels) using the Input image, and save the signature to the ROI Signature list;
  • Extent input_list: extent of the Scatter raster; available options are:
    • Same as display: extent is the same as map display;
    • Same as image: extent is the same as the whole image;

7.1.2. Plot

Left click and hold inside the plot to move the view of the plot. Use the mouse wheel to zoom in and out the view of the plot. Right click and hold inside the plot to zoom in a specific area of the plot.

  • Colormap input_list enter: select a colormap that is applied to highlighted scatter plots in the list when enter is clicked; if no scatter plot is highlighted then the colormap is applied to all the scatter plots;
  • fit_plot: automatically fit the plot to data;
  • save_plot_image: save the plot image to file (available formats are .jpg, .png, and .pdf);
  • x y: display x y coordinates of mouse cursor inside the plot;


Example Scatter Plot