Book Image

QGIS 2 Cookbook

By : Alex Mandel, Víctor Olaya Ferrero, Anita Graser, Alexander Bruy
Book Image

QGIS 2 Cookbook

By: Alex Mandel, Víctor Olaya Ferrero, Anita Graser, Alexander Bruy

Overview of this book

QGIS is a user-friendly, cross-platform desktop geographic information system used to make maps and analyze spatial data. QGIS allows users to understand, question, interpret, and visualize spatial data in many ways that reveal relationships, patterns, and trends in the form of maps. This book is a collection of simple to advanced techniques that are needed in everyday geospatial work, and shows how to accomplish them with QGIS. You will begin by understanding the different types of data management techniques, as well as how data exploration works. You will then learn how to perform classic vector and raster analysis with QGIS, apart from creating time-based visualizations. Finally, you will learn how to create interactive and visually appealing maps with custom cartography. By the end of this book, you will have all the necessary knowledge to handle spatial data management, exploration, and visualization tasks in QGIS.
Table of Contents (19 chapters)
QGIS 2 Cookbook
Credits
About the Authors
About the Reviewers
www.PacktPub.com
Preface
Index

Preparing elevation data


In this recipe, we will show you how to perform terrain analysis in QGIS. Terrain analysis algorithms assume certain characteristics in the DEMs that are used as inputs, so it is important to know them and prepare these DEMs if they are needed. This recipe shows you how to do this.

Getting ready

Open the dem_to_prepare.tif layer. This layer contains a DEM in the EPSG:4326 CRS and elevation data in feet. These characteristics are unsuitable to run most terrain analysis algorithms, so we will modify this layer to get a suitable one.

How to do it…

  1. Reproject the layer to the EPSG:3857 CRS, using the Save as... entry in the context menu that appears by right-clicking on the layer name.

  2. Open the resulting reprojected layer.

  3. Open the Processing raster calculator and select the reprojected layer as the only raster input in the Input layers field. Enter a * 0.3048 in the Formula field. Run the algorithm.

How it works…

Most of the algorithms that we are going to use assume that the...