Tag Archives: Tutorial

This is a guest post by Mickael HOARAU @Oneil974

For people who are working on QGIS Atlas feature, I worked on an Atlas version of the last tutorial I have made. The difficulty level is a little bit more consequente then last tutorial but there are features that you could appreciate. So I’m happy to share with you and I hope this would be helpful.

This slideshow requires JavaScript.

You can download tutorial here:

Material Design – QGIS Atlas Tutorial

And sources here:


PS : I’m looking for job offers, feel free to contact me on twitter @Oneil974


Profile Tool is a plugin for QGIS which makes it possible to generate (elevation) profiles for line features. The plugin is available through the default QGIS plugin repository. While testing the plugin, I found some aspects of using the tool might require additional instructions.

After installing and enabling the plugin, you will find the “Terrain profile” button in the plugin toolbar:


The basic use case is as follows:

  1. Load the elevation raster and select this raster layer in the layer list.
  2. Press the “Terrain profile” button. This opens the plugin panel which consists of a graph area on the left and a raster layer list on the right. The raster layer you had selected will be added to the raster layer list.
  3. If you have “Selection: Temporary polyline” enabled, you can now draw a line in the map area. Double-click left to end drawing the line. (If you are paying close attention, you might have noticed the instructions in the status bar.)
  4. After you have finished drawing the line, the graph area will update and display the profile.


If you want to add another raster layer to the plugin, you need to first select the raster layer in the QGIS layer list and then press the “Add Layer” button in the Profile Tool panel.

To generate the profile for an existing line feature, you need to change the selection mode from “Temporary polyline” to “Selected polyline”. Then you need to select the vector layer which contains the line feature you want to use in the QGIS layer list. Finally, you can click on the line feature in the map area to select it. (Note that this selection is independent of any selections you might have going on using the default QGIS feature selection tools.)

If you change from the Profile Tool to any other tool such as “Pan Map” or “Identify”, you have to click the “Terrain profile” button again to re-enable drawing/selection a line for the Profile Tool.

Due to a bug, it is currently not possible to export the profile graph. An alternative is to open the “Table” tab of the Profile Tool panel which provides access to the profile data and copy the data into your preferred graphing application such as Calc or Excel.

If you want to see the Profile Tool in action, I recommend watching the introduction video by Lene Fischer (University of Copenhagen).

Group Stats is a plugin for QGIS which makes it easy to calculate statistics for feature groups in a vector layer. Note that the plugin is still marked “experimental” so you have to allow experimental plugins in order to install it. I tried this plugin for the first time today and decided to write this post because it didn’t seem immediately obvious how to use it.

The plugin button is added to the vector toolbar and of course you can access it via vector menu.


The example I want to show is: How to calculate the total area of each Corine Land Cover (CLC) class per state.


After adding state information to the CLC datasets by intersecting CLC and state geometries from Natural Earth we can get started with Group Stats.


The big area on the left will display the results. The input fields are on the right. The general idea is to drag and drop fields and/or functions into the “columns”, “rows” and “values” sections. (Double-clicking field names does not do anything.) To remove fields again, you have to drop them back into the field list.

To calculate the total area of of each Corine Land Cover (CLC) class per state, I chose land cover classes as columns, state names as rows and sum of areas as values:


It’s also possible to add multiple functions in the columns/rows input sections to calculate different statistics at once:


Group Stats can be used in many cases that otherwise require a Spreadsheet software. The results can be exported to CSV easily. Usability could certainly be improved by allowing common interactions such as removing fields by pressing the delete key or adding fields by double-clicking.

QGIS wiki now has it’s own section listing QGIS video tutorials.
If you know of any tutorials not listed yet, leave a comment and I’ll add them.

Together with the newly started “How to I do that in QGIS” tutorial collection, this will hopefully become the number one reference for both new users doing their first GIS-related work and advanced uses interested in the latest QGIS features.

The OSGeo Education and Curriculum Project provides a knowledge base for everyone interested in working with geoscience in general and open source GIS specifically. Everybody is invited to contribute and upload/link their educational material to the database for the benefit of the community.

The database already contains a number of QGIS related materials, e.g. “GIS Basics with Quantum GIS” by Micha Silver.

SpatiaLite doesn’t need to be installed [1], just get SpatiaLite and unpack it in – for example – ~/apps (tested on Ubuntu 9.4):

~$ mkdir apps
~$ cd apps
~/apps$ wget
~/apps$ tar xvfz spatialite-tools-linux-x86-2.3.1.tar.gz

Now you should be able to run it. Let’s create a test database:

~/apps$ cd ~/temp
~/temp$ ~/apps/spatialite-tools-linux-x86-2.3.1/bin/spatialite testdb.sqlite

Then we have to initialize the new database with some metadata. We need a script called init_spatialite-2.3.sql (get it from It will create the tables “geometry_columns” and “spatial_ref_sys”.

spatialite> .read '~/init_spatialite-2.3.sql' ASCII

For testing purposes, we’ll now load a shapefile into our new database. I used a Teleatlas street graph (attribute encoding iso-8859-15) and created a “streets” table:

spatialite> .loadshp ~/maps/streetgraph streets iso-8859-15

Finally, we register the geometry columns … pretty similar to PostGIS:

spatialite> UPDATE streets SET Geometry = SetSrid(Geometry,4326);
spatialite> SELECT RecoverGeometryColumn('streets','Geometry',4326,'LINESTRING',2);

Done! That’s it. Now we can view our test data in QGIS. For a longer Tutorial check


%d bloggers like this: