Category Archives: tools

A Zim-wiki export template for a adaptive website

I wrote before about Zim, a graphical text editor used to maintain a collection of wiki pages. Although mostly aimed at individual use, notebooks can also be shared as html files (and a few other formats) by exporting the notebook or individual pages as web pages, as explained here. And to give you an idea what you can get, see here an example of one of my notebooks.

For one of my projects I wanted to create a small web-site with fact sheets that provide a short description of vegetation types in eastern Africa. These fact sheets go together with vegetation maps we have created for various countries in the region. The idea was to keep the fact sheets as notes in a Zim notebook, and use the export function to create a small web-site. Continue reading

A new method and tool (ExDet) to evaluate novelty environmental conditions

A common objective of correlative species distribution model is to be able to project the potential distribution of the target species into a new environmental space. This can be a new geographic space (e.g., invasive species) or projected future conditions.

One should be very careful in interpreting results if extrapolating to areas with conditions that fall outside the range of reference environmental variation. There are several methods to visualize this uncertainty. On this blog I have for example mentioned the multi-environmental similarity tool in Maxent (also implemented in R in amongst others the dismo package and as an addon for GRASS GIS), which allows you to create maps that provides the similarity of each point to a set of reference points (Elith et al. 2010) and thus provide a quick overview of areas with ‘novel’ conditions.

A disadvantage of this and other methods is that they only consider the ranges of the individual predictors, and ignore the correlation structure of the covariates used to build the model. In reality, it is not unlikely that at a given locations values of each univariate factor fall within the original range of values, but the combination of environmental conditions is new. Continue reading

A plugin to export layers in GIMP file to single pdf file

Update: there is another plugin that export Layers to single multiple pages PDF. You can get the plugin here: http://registry.gimp.org/node/27987. I haven’t tried it yet, so I can’t tell you how it differs from the one described below. But of course, there is nothing stopping you from trying them both. If you do, let me know which one you like best :-).

A while back I wrote about two possible ways to export multiple layers in GIMP to one pdf file using third-party tools. But it turns out there is an much easier solution as Nevar pointed out in the comments on that blog post. The ‘Export Layers as PDF’ plugin for GIMP. You can get the plugin from the Gimp plugin registry. See here for instructions how to install the plugin.

After installing you need to restart GIMP after which you can find the new function in the file menu (see screenshot). Continue reading

Update of the r.forestfrag addon for GRASS GIS

Some time ago I came across this post from Sylla Consult about a script to calculate forest fragmentation index suggested by Riitters et al. (2000). Obviously, it can be used for any land cover type, so perhaps landscape fragmentation index would be a better name. Anyway, the script r.forestfrag.sh is available from the GRASS-addons page.

Unfortunately, it only worked with GRASS 6.4. Because I mostly work in GRASS 7.0 I adapted the script to make it work on GRASS 7.0.  I also added some additional options and changes: Continue reading

Sharing or exporting sub-sections of a ZIM notebook

I use ZIM desktop wiki to keep all kind of notes. Sometimes I want to share my notes. This is easy enough when I want to share the whole notebook. I simply send the whole folder containing the ZIM notebook (zipped or not) to my collaborator.

But what if you want to share only a section of the notebook? On a similar note, what if I want to export part of my notebook as html files? Continue reading

Point coordinates to polygon – part II

In my previous article, I showed how you can convert point coordinates into a polygon vector layer in QGIS. So how about GRASS GIS? Like in my previous post, let’s assume you have a text file with two columns with the coordinates. With the v.in.ascii function you can import this text file as a point layer. Next, you can use v.hull or v.delaunay to create polygon layers.

With a little bit more work, you can convert the above mentioned text file into a ASCII vector file. Continue reading

Looking for a pdf reader with good annotations options

I read my articles on my (Android) tablet or on my computer (Ubuntu 12.10). On both, I want to be able to add notes and underline and highlight text.  For Android there are various apps that allow you to to do this (the two I am currently using are RepliGo pdf reader and Moon+ reader, but there are more options). For Linux, I found it surprisingly difficult to find a package with good annotation capabilities. Continue reading

Calculating the raster cell area of an unprojected raster layer

What if you get a raster layer with number of people per raster cell, like for example the population layer from Afripop,  and you want to convert it to a population density layer?

Well, obviously, you need to divide the number of people by the surface area of the raster cells. However, the surface area of the raster cells of an unprojected (lat/lon) are not constant; they decrease with increasing latitude. So what you need is a raster layer with the surface areas of the cells.

I thought I had seen a function in GRASS GIS to do this, but that might have been a typical case of the wish being the father to the thought. But anyway, it isn’t terribly difficult to calculate it yourself using the map calculator. Continue reading

Extracting lines ending with specific character using sed or grep

A quick note (to myself mostly) about how to extract lines from a text file that end with a specific set of characters. In Linux, you can very easily do this using ‘grep’ or ‘sed’. But, first a little bit of background. Continue reading