Creating simple reports using Reporter for QGIS

Материал из GIS-Lab
Перейти к: навигация, поиск
Эта страница опубликована в основном списке статей сайта
по адресу http://gis-lab.info/qa/reporter-eng.html


QGIS plugin for simple reports generation

Reporter is a QGIS plugin, that allows to generate simple reports for spatial features located within certain area of interest. To use this plugin you will need a project with vector layers and area of interest (another layer) — polygon feature used to generate reports.

Typical usage scenario for Reporter is to check if any valuable features are located in some area and to assess the area and number of these objects.

This plugin was developed by NextGIS for the UNDP/GEF project "Conservation and sustainable use of biological diversity in Russia’s Taymir Peninsula".

Создано в Nextgis.png Веб ГИС для вашей организации по доступной цене

Содержание

Installation notes

Plugin is available via official repository.

Reporter is designed for QGIS version 1.8.0 and higher. There are no dependencies, all necessary files are included in package.

You can also obtain sources from our SVN:

svn co http://svn.gis-lab.info/reporter reporter

Creating area of interests

Area of interest (AOI) is a polygonal feature used to generate report. There are several ways to create such feature.

Load AOI from existing file

QGIS supports many different vector data formats such as ESRI Shapefiel, KML, DXF, MapInfo (mid/mif, tab), GML and others.

To add existing vector file to project press "Add Vector Layer" button

"Add Vector Layer" button

or select "Add Vector Layer" from "Layer" menu:

"Layer"menu

Dialog will appear:

"Add Vector Layer" dialog

Select "File" in "Source type" group, then press "Browse". Standard open file dialog will open, where you should select file. After pressing "Open" this file will be loaded in QGIS as a layer.

More detailed description can be found in Chapter 4 of QGIS User Guide, for example adding layers is described in sections 4.1.1 - 4.1.4.

Creating polygon by entering vertex coordinates

Before creating new polygon by entering vertex coordinates it is necessary to open existing or create new layer. This process is described in section 4.5.5 of QGIS User Guide. Note: you need to open or create polygonal layer.

When layer is opened/created start editing by pressing "Toggle editing" button. Several buttons will become available, among them there will be button «Numerical Digitize» (if you don't have it, install a plugin with the same name).

"Numerical Digitize button

After pressing this button a dialog will appear:

"Numerical Digitize" dialog

Using this dialog you will add coordinates of polygon vertices in project CRS ("in the CRS of the Project"), of in layer CRS ("in the CRS of the Layer"). If coordinates are geographical, choose the second option. When all coordinates are added press "OK" button. New polygon will be added.

Create polygon from point and bufer distance

As in the previous case, first open existing or create new point layer where buffer center will be added. Then start editing and create point in the center of future AOI using "Add Feature" tool. When point added stop editing.

Now go to "Vector → Geoprocessing Tools → Buffer(s)». A dialog will appear

"Buffer(s)" dialog

Select point layer from "Input vector layer" dropdown. If needed activate "Use only selected features" checkbox. Enter buffer radius in layer units to "Buffer distance" field. Using field "Segments to approximate" you can control "smoothness" of the result.

Enter output filename in "Output shapefile" field and press "OK". In few seconds new layer will be created and added to the map.

Digitizing AOI manually

This can be done in existing or new layer.

Create new or open an existing layer and start editing. Digitize new polygons using tools "Add Feature", "Add part", "Delete part", "Split features" etc. When finished, save edits and stop editing.

Detailed description is available in section 4.5 of QGIS User Guide.

How does it work

Running

After plugin installation startup the plugin by clicking button:

Plugin button

main plugin window will appear:

Plugin window, "Layers" tab
Pugin window, "Settings" tab

In the "Layers" tab all major controls are located. Combobox "Area of interest" is used to select polygon layer with AOI boundaries. Important! By default, if there are several features in AOI layer, the plugin will use the last feature. If you want to use another feature — select it with "Select single feature" tool.

Selection tool

If several features are selected — the last from selected feature will be used. Some methods to create areas of interest are described in section Creating area of interests.

There is also project layers list. On first run this list is disabled, to activate it press "New" button. This will create a new profile (a set of layers settings).

From the list you can select layers that will be processed and results will be added to the report. Important! Only layers with «Unique values» style (new or old symbology) can be used. If layer with different style is selected, it will be ommited during processing.

Reports types

When layer is selected an additional dialog will appear, where you can set some settings related to the type of the report needed:

Layer settings

This dialog allows to choose report types. Currently two reports types are available:

  • Distribution of the AOI over areas occupied by features with some characteristics (i. e. partitioning by classes), as well as percentage of each class inside total area. Check "Create table with areas" to activate
Areas table example
  • List of objects that fall into AOI (and their frequency) with loading labels from selected attribute field. Check "Extract layer objects" to activate:
Objects table example

Other settings

Here you can select another field to label features in tables. By default classification field used to show the layer on the map is used. This can be useful if you want to have in table values from the field which is different from the classification field.

In the "Comment" field you can specify optional text which will be added to description from global settings. This text will be added before every report. This can be used for example to add links to the extended legend description.

After closing this dialog you can open it again be doubleclicking on the layer name in the list.

Layers setup and their settings can be saved for futher usage as an XML parameters file by pressing "Save" button. It is also possible to load existing profile.

In "Report" field you will need to specify path and name of the final report file. Report will be created in Microsoft Office 2003 XML format.

To start report generation press "OK" button, the progress will be displayed by layers processsed.

Maps creation

The plugin can also create simple maps with AOI and analyzed layer. These maps can be saved on disk or embedded in the report. If "Create thematic maps" checkbox is checked then for every layer simple map in PNG format will be generated. These maps are saved in the same folder with the report and have same names as source layer name.

If "Also embed maps in report" is checked, then thematic maps will be also added to the report itself after tables.

Thematic map example

If "Load last configuration" if checked and profile was saved, then on next startup the plugin will load this configuration. It is useful if you need ofter generate same reports with same settings

Group "Area dimensionality" is used to control calculated areas dimensionality. Here you can specify coefficient used in calculations:

  • 10^0 — square meters
  • 10^4 — hectares
  • 10^6 — square kilometers

In the last field you can specify text which will be added before each report.

Contacts

If you want to report a bug or want to make a suggestion — use bugtracker. If you have any other inquiry, you can contact us directly.

Links

Персональные инструменты
Пространства имён

Варианты
Действия
Статьи
Спецпроекты
Инструменты