View source: R/estConnectivity.R
estMantel | R Documentation |
Resampling of uncertainty for migratory connectivity strength, as quantified by Mantel correlation (rM), from geolocators, GPS, and/or raster (e.g., genoscape or isotope) data.
estMantel(
targetPoints = NULL,
originPoints = NULL,
isGL,
geoBias = NULL,
geoVCov = NULL,
targetSites = NULL,
nBoot = 1000,
nSim = ifelse(any(isRaster & isGL), 5000, ifelse(any(isGL), 1000, ifelse(any(isRaster),
10, 1))),
verbose = 0,
alpha = 0.05,
resampleProjection = "ESRI:102010",
maxTries = 300,
maintainLegacyOutput = FALSE,
originSites = NULL,
isTelemetry = !isGL,
isRaster = FALSE,
captured = "origin",
geoBiasOrigin = geoBias,
geoVCovOrigin = geoVCov,
targetRaster = NULL,
originRaster = NULL,
dataOverlapSetting = c("dummy", "none", "named"),
originRelAbund = NULL,
targetRelAbund = NULL
)
estCorr(
targetPoints = NULL,
originPoints = NULL,
isGL,
geoBias = NULL,
geoVCov = NULL,
targetSites = NULL,
nBoot = 1000,
nSim = ifelse(any(isRaster & isGL), 5000, ifelse(any(isGL), 1000, ifelse(any(isRaster),
10, 1))),
verbose = 0,
alpha = 0.05,
resampleProjection = "ESRI:102010",
maxTries = 300,
maintainLegacyOutput = FALSE,
originSites = NULL,
isTelemetry = !isGL,
isRaster = FALSE,
captured = "origin",
geoBiasOrigin = geoBias,
geoVCovOrigin = geoVCov,
targetRaster = NULL,
originRaster = NULL,
dataOverlapSetting = c("dummy", "none", "named"),
originRelAbund = NULL,
targetRelAbund = NULL
)
targetPoints |
A |
originPoints |
A |
isGL |
Indicates whether or which animals were tracked with geolocators
Should be either single TRUE or FALSE value, or vector with length of
number of animals tracked, with TRUE for animals in |
geoBias |
For GL data, vector of length 2 indicating expected bias
in longitude and latitude of |
geoVCov |
For GL data, 2x2 matrix with expected variance/covariance
in longitude and latitude of |
targetSites |
A |
nBoot |
Number of bootstrap runs. Animals are sampled with replacement for each, to estimate sampling uncertainty. |
nSim |
Tuning parameter for GL or raster data. Affects only the speed; 1000 seems to work well with our GL data. Should be integer > 0. |
verbose |
0 (default) to 3. 0 prints no output during run. 1 prints a line every 100 bootstraps. 2 prints a line every bootstrap. 3 also prints the number of draws (for tuning nSim only). |
alpha |
Level for confidence/credible intervals provided. |
resampleProjection |
Projection when sampling from geolocator
bias/error. This projection needs units = m. Default is Equidistant
Conic. The default setting preserves distances around latitude = 0 and
longitude = 0. Other projections may work well, depending on the location
of |
maxTries |
Maximum number of times to run a single GL bootstrap before exiting with an error. Default is 300. Set to NULL to never stop. This parameter was added to prevent GL setups where some sample points never land on target sites from running indefinitely. |
maintainLegacyOutput |
version 0.4.0 of |
originSites |
A |
isTelemetry |
Indicates whether or which animals were tracked with telemetry/GPS (no location uncertainty on either end). Should be either single TRUE or FALSE value, or vector with length of number of animals tracked, with TRUE or FALSE for each animal in data. |
isRaster |
Indicates whether or which animals were tracked with
intrinsic markers (e.g., genetics or isotopes), with location uncertainty
expressed as a raster of probabilities by grid cells, either in
|
captured |
Indicates whether or which animals were captured in the origin sites, the target sites, or neither (another phase of the annual cycle). Location uncertainty will only be applied where the animal was not captured. So this doesn't matter for telemetry data. Should be either single "origin" (default), "target", or "neither" value, or a character vector with length of number of animals tracked, with "origin", "target", or "neither" for each animal. |
geoBiasOrigin |
For GL data where |
geoVCovOrigin |
For GL data where |
targetRaster |
For intrinsic tracking data, the results of
|
originRaster |
For intrinsic tracking data, the results of
|
dataOverlapSetting |
When there is more than one type of data, this setting allows the user some flexibility for clarifying which type(s) of data apply to which animals. Setting "dummy" (the default) indicates that there are dummy values within each dataset for the animals that isGL, isTelemetry, etc. don't have that data type (FALSE values). If no animals have a data type, no dummy values are required. If no animals have more than one type of data, the user can simplify processing their data by choosing setting "none" here. In this case, there should be no dummy values, and only the animals with a type of data should be included in that dataset. The third setting ("named") is not yet implemented, but will eventually allow another way to allow animals with more than one type of data with named animals linking records. When there is only one type of data, it is fastest to leave this on the default. |
originRelAbund |
the proportion of the total abundance in each of B
|
targetRelAbund |
the proportion of the total abundance in each of W
|
estMantel
returns a list with elements:
corr
List containing estimates of rM:
sample
nBoot
sampled values for Mantel
correlation. Provided to allow the user to compute own summary
statistics.
mean, se, simpleCI, bcCI, median, point
Summary
statistics for Mantel correlation bootstraps.
input
List containing the inputs to estMantel
Cohen, E. B., J. A. Hostetler, M. T. Hallworth, C. S. Rushing, T. S. Sillett, and P. P. Marra. 2018. Quantifying the strength of migratory connectivity. Methods in Ecology and Evolution 9: 513 - 524. \Sexpr[results=rd]{tools:::Rd_expr_doi("10.1111/2041-210X.12916")}
estMC
data('OVENdata')
rM1 <- estMantel(isGL=OVENdata$isGL,#Logical vector: light-level GL(T)/GPS(F)
geoBias = OVENdata$geo.bias, # Geolocator location bias
geoVCov = OVENdata$geo.vcov, # Location covariance matrix
targetSites = OVENdata$targetSites,#Nonbreeding/target sites
originPoints = OVENdata$originPoints, # Capture Locations
targetPoints = OVENdata$targetPoints, # Target locations
verbose = 1, # output options
nBoot = 10, # This is set low for example
resampleProjection = sf::st_crs(OVENdata$targetSites))
rM1
str(rM1, max.level = 2)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.