No that's too far, zoom out a little... Ugh. Micro-adjustments to zoom in Google maps

Ever find that zooming in or out by clicking on the + or - button is too abrupt? You can set the zoom level with a decimal value to make some micro adjustments.

For example, you can specify the zoom level in Earth Engine using the .centerObject() function. Here we'll zoom in to Rome, Italy (the G20 summit is being held there today).

Nice, a map of Rome...

But wait, that's not enough. Zoom in a bit more...

Better, but it's too far! Zoom back out just a bit...

Perfect! This last map provides (for this example) just the right zoom level to see the details and the context I desire. Here's a quick worked example in GEE.

Bonus tip: you can do the same thing in Google maps too! So, here's the URL string from my search for Rome. The first URL is the result from my search for Rome:

This one is modified just at the end of the string just before the "z", to zoom to level 11.5:




Excited to be attending an in-person meeting again! I am presenting on the need for better global ecosystem mapping and leading an Ecological Connectivity networking session at the North American Congress on Conservation Biology 2022.

Multiple ways to calculate new images based on a conditional expression


A common task is to calculate a new image based on the values of an existing image (or multiple images). (Many other GIS programs call this a "raster calculator").

But, it turns out that doing this with more than one or two conditional expressions is a bit unwieldy in EE. For example, what if we wanted to identify vegetational "life zones" that are often characterized by elevational thresholds, defined as: alpine is greater than 11,500 feet upper montane forest is below alpine and greater than 8,000 feet lower montane forest is below upper montane, that is less than 8,000 feet I've worked out three ways this can be accomplished here in EE code -- moving from a simple to a slightly more involved approach -- but the benefits are vastly increasing the power and flexibility of your code.

Enjoy, and Happy Halloween!

Landscape patterns: landscape signature code


Here's the link to the Google Earth Engine code to demonstrate the landscape signature metric. See this post for a brief description of this approach.

Landscape signature is a simple, informative, and robust metric to analyze landscape patterns, particularly of "patches" of a discrete unit such as habitat patches. This metric builds on the GISFrag metric (Ripple et al. 1991) computes fragmentation by computing the average distance from the nearest patch and accounts for the configuration of patches. This metric assumes a binary landscape (e.g., habitat/non-habitat), and is computed by finding the straight-line distance away from patches (shown in white below). Smaller distance values from the edges of polygons indicate less fragmented landscapes and larger values indicate higher levels of fragmentation (see darker brown colors in second image below). A summary measure of GISFrag is typically calculated as the mean of the distance values.

This approach can be extended to a measure not just the configuration of patches within the matrix, but measure the size and shape of patches themselves (darker green areas are "cores").

And, developing a graph as a "signature" of the landscape assists greatly in a deeper and more robust understanding of the patterns. Both the shape and configuration of patches in a landscape can be examined by measuring how the proportion of a landscape that is occupied by patches changes when patches are enlarged (buffering out) and shrunk (buffering in) across a range of scales. This can be computed by calculating both the straight-line distance away from and into the patches. Notice that the proportion of patch “habitat” is shown by the frequency of pixels at the intersection of 0 with the x-axis. The shape of the curve with positive values indicates the configuration of the patches, while negative values reflect the number, shape, and size of the patches.

So, how do you calculate this in Google Earth Engine? How are results of this metric used? What are its particular sensitivities? More information and scripts are provided in this link provided in the Geographical Analysis using Google Earth Engine learning materials.

Ripple, W.J., G.A. Bradshaw, and T.A. Spies. 1991. Measuring forest landscape patterns in the Cascade Range of Oregon, USA. Biological Conservation 57: 73-88.