LecoS stands for "Land cover statistics." It is a plugin for QGIS made by Martin Jung to convert raster data to arrays. An array, according to Wikipedia is a "systematic arrangement of objects, usually in rows and columns." It uses a Python package called NumPy to do this, so as you will see you will need to download certain Python packages to make LecoS work.
LecoS calculates the landscape metrics for patches of your map. According to UMass.edu, landscape metrics quantify certain spatial characteristics of patches on a map. Composition metrics can look at "Proportional abundance of each class" (how much is there of this type compared to the rest?), "Richness" (how many of this type?), "Evenness" (dominance or diversity of a type), and "Diversity" (a composite of richness and evenness). Spatial configuration metrics look at many things, such as where a patch is located relative to another, position, and orientation.
Getting Started
Before you can use this plug-in, you may need to download some packages to make it work. Kyng Chaos's Wiki has all the necessary packages available for download for MacOS. NumPy, SciPy, and PIL are the three you will need to run LecoS.
How to Download the Package
- Clink on the download link
- 'Save File' to a directory or file that you will be able to find easily
- Go to the file and open it
- Follow the tutorial to install
- Restart QGIS and try installing LecoS plugin. If there is still a missing Python package there will be an error. You may need an additional package.
Martin's Walk-Thru
I followed Martin's walk-thru on his blog to learn this plugin. The first step was to download a raster image called the Corine dataset, which shows Europe. Once the zip is downloaded you can unzip it and then load the .tif file into QGIS as a raster layer. He then wants you to crop to a smaller area. To crop a raster file, to go "Raster", "Extraction", "Clipper". This tool will allow you to crop an area using your cursor.
This is my cropped view. I zoomed in on Athens, Greece.
Then using the actual plugin we make some specifications. The plugin is found under "Raster", "Landscape Ecology", "Landscape Statistics".
As you can see in the image, choose your cropped raster (mine is called "athens"), cell size should be 100, choose to save the file as a csv, and of course, choose your metrics. Martin suggests using "Land cover," "Landscape Proportion," and "Number of patches."
The resulting file will be a .csv that can be opened with excel, etc. However, when I first opened mine with excel, there were semicolons instead of commas, which excel doesn't recognize so everything was in one column. To fix this (with Dan's help), I opened the .cvs in textedit and replaced all the semicolons with commas. Do this by using the "Find and Replace" command under "Edit."
Now when I open my .csv in excel it looks like this:
The next step in this project should be to research how to analyze the data that LecoS produces.
Helpful Links
Conservation Ecology: LecoS
A quick and dirty walk-thru for downloading LecoS on Windows: HERE!
How to Crop Raster Layer
Page by Meagan T.