This builds from the previous series of posts on this topic
This model is very similar to that shown on the previous post. However a key difference is the use of minimum edge to edge distances measured in a GIS instead of distances between centroids. The files can be obtained from th link below. The model that uses edge2edge distances is in the zip file.
## HOW IT WORKS
The key difference lies in this code block.
foreach gis:find-less-than edge2edge “distance” sep_dist [
let to_gid gis:property-value ? “to_gid”
let from_gid gis:property-value ? “from_gid”
let dist gis:property-value ? “distance”
if to_gid != from_gid [
ask one-of habitats with [gid = from_gid]
[create-link-with one-of other habitats with [gid = to_gid ]
[set dist dist]
Centroids are loaded using the GIS extension. However in this version the links are provided by loading a file containing linestrings of known length that represents the shortest edge to edge distance between patches. This layer has been built using a query in PostGIS.
This greatly improves the way the model handles connectivity. The improvement can best be seen when the vector polygons are added, as the model will connect large patches much better than the more simplistic version using distances between centroids.
## HOW TO USE IT
As the model stands it is still only useful for teaching the concept.
Sensitivity could be analysed using the behaviour space tool. While the model is too simplistic to represent any real situation it is paramaterised using real GIS data and therefore can be related to a known landscape. In this case, the New Forest, but other vector layers can easily be used.
## THINGS TO NOTICE
The model does not take into account the area of the habitat when evaluating extinction risk.
Notice that the grey links are between centroids as before. Their “distance” property however is determined edge to edge. So long lines may in fact represent short distances. The reverse of the tube map!
## THINGS TO TRY
Change any of the parameters.
Watch the ouptut in order to see on which parts of the network the populations persist.
## EXTENDING THE MODEL
Many more realistic elements could be built from here.
As the habitat nodes do know about their area this could fairly easily be incorporated in the model True interpatch distances are also known, so dispersal could be made more realistic. If cost surfaces were included it would probably be better to use an individual based ABM rather than patch based.