“Raster data is gridded data with discrete values which forms a matrix of cells or pixels which can be represented in a spatial context”
In simple terms, raster data is a matrix of cells with specific values that are organized into columns and rows.
Each cell in the matrix of data may contain multiple values, each of which is retained in a single band. Bands may be understood, in very simple terms, to function like distinct layers within a raster file. Many aerial imagery rasters, for example, contain a separate band for Red, Green, and Blue (RGB) values. More complex imagery types may contain additional bands, which might be used for storing infrared or hyperspectral information as well. More advanced data formats also support arrays of data overlaid on top of each other, which may be used for storing data such as time-series information.
QGIS supports a wide variety of raster formats by leveraging the Geospatial Data Abstraction Library, or GDAL, to read and write various spatial data formats, and supports over 150 raster data types. Note, however, that although many data format types can be opened within QGIS, writing/ exporting is not supported for all file formats.
Raster data is commonly used as a base map for outlining regional geography for a particular area of interest, as well as for remote sensing and data analysis operations. One of the most common functions of raster data is the capturing of vector data (digitizing) of geographic features from aerial photographs or other raster sources so that the features may be used for spatial analysis.
Depending on the data stored, raster data may be much larger in file size than a vector dataset (depending on the level of detail). Various compression algorithms attempt to facilitate storing raster data with smaller file sizes, but this may be at the cost of performance or data quality, so should be used with care. Raster analysis, however, can be much more performant than similar operations when applied to vector analysis, especially when applied to regions of large extents. Knowing when to choose or convert between raster and vector data sources for analysis operations is a key skill for GIS professionals.
Raster data can be categorized into three broad categories, outlined as follows:
Goal: To explore how to load raster data in QGIS
Exercise 01: Opening raster data from the file browser
Exercise 02: Opening raster data from the QGIS Browser Panel
Check your results
How many layers are now visible in your layer list?
Did all of the data loading methods work for you? If not, can you identify what when wrong?
Were you able to identify the different data types in the file browser and the QGIS Browser?
Did you notice how the browser automatically identified suitable data types for you?
Can you identify which files in the exercise folder are raster data files and which are supporting files?
The data provided by common GIS Web Services is often raster data, which is often supplied in a tiled format. Raster tiles can be generated by GIS applications and served from a remote source, providing easy access to base map data in an efficient way that only loads the source tiles for the currently viewed extent. XYZ tile services are a common method of providing raster data as a service. These services are supported natively in QGIS, and QGIS additionally includes an XYZ tile service from the OpenStreetMap project by default.
When loading data into QGIS it is important to filter the data based on the extensions. The most common format of raster data is the geographic Tagged Image Format, or geotiff, which have the common file extensions of .tif, .TIFF, or .tiff. Loading layers using the browser panel has significant advantages because it automatically filters for the correct format to be loaded in QGIS. A raster layer may also have auxiliary files that are associated with it. Some of the additional files that may be associated with a raster dataset are outlined in the following table.
File Extension | Explanation |
---|---|
.prj |
A file with projection definition for the layer |
.qml |
QGIS specific file that defines the visual style of the raster data (Symbology) |
aux.xml |
A file with raster statistics |
.xml |
Metadata file describing the characteristics of the raster |
Which statement best describes and image taken with a phone camera:❗
What is one distinct advantage of adding raster layers using the browser panel:❗
Can raster layers be stored in a database:❗
Download the sample data for the lesson.