| connectivity | R Documentation | 
Calculate thermal connectivity and potential for temperature change.
connectivity(img, conn_threshold = 1.5)
img | 
 A numeric temperature matrix (such as that returned from
  | 
conn_threshold | 
 Climate threshold to use for calculation of thermal connectivity (i.e. the amount of change that organisms would be seeking to avoid).  | 
This measure of climate connectivity and potential for temperature change is analogous to that described in McGuire et al. 2016. The basic premise is that there is a degree of change that organisms are seeking to avoid, and when pixels are sufficiently heterogenous and well connected organisms can move through the pixels to avoid deleterious temperature change.
A dataframe (one row for each pixel) containing:
x, y | 
 The original spatial location of the pixel  | 
val | 
 The pixel value  | 
pixel | 
 The unique id given to the pixel  | 
dest_pixel | 
 The id of the final destination pixel  | 
dest_val | 
 The value of final destination pixel  | 
inter_pixel | 
 The intermediate pixels traversed from origin to destination pixel  | 
diff_potential | 
 The potential for change achieved by following gradient from hotter to cooler pixels  | 
therm_conn | 
 Thermal connectivity, calculated as the maximum potential
change (  | 
McGuire, J. L., Lawler, J. J., McRae, B. H., Nunez, T. A. and Theobald, D. M. (2016), Achieving climate connectivity in a fragmented landscape. PNAS, 113: 7195-7200. https://doi.org/10.1073/pnas.1602817113
# Define matrix as FLIR thermal image
img <- flir11835$flir_matrix
# Get connectivity
img_conn <-
connectivity(img = img,
             conn_threshold = 1.5)
head(img_conn)
# Plot the potential for temperature change
library(ggplot2)
ggplot(img_conn, 
       aes(x = x, y = y, fill = diff_potential))+
    geom_raster() +
    scale_fill_viridis_c()
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.