Install necessary packages and import appropriate data
pacman::p_load(tidyverse, readxl, raster, vegan, tigris, sf, sjPlot, sp, spOccupancy, ggrepel, lme4, lmerTest, MuMIn, brms, MCMCvis)
set.seed(97)
# Tree PCQ Data
tree_data <- read_excel("C:/Users/DrewIvory/OneDrive - University of Florida/Desktop/School/PHD/01_Projects/05_SharedData/Field_Data_FL_AL_MS.xlsx",
sheet = "Tree_PCQ")
# Soil Data
fuel_data <- read_excel("C:/Users/DrewIvory/OneDrive - University of Florida/Desktop/School/PHD/01_Projects/05_SharedData/Field_Data_FL_AL_MS.xlsx",
sheet = "Fuel_Sampling")
# Veg Data
Veg_Cover <- read_excel("C:/Users/DrewIvory/OneDrive - University of Florida/Desktop/School/PHD/01_Projects/05_SharedData/Field_Data_FL_AL_MS.xlsx",
sheet = "Veg_Cover")
# Shrub Cover Data
shrub_data <- read_excel("C:/Users/DrewIvory/OneDrive - University of Florida/Desktop/School/PHD/01_Projects/05_SharedData/Field_Data_FL_AL_MS.xlsx",
sheet = "Shrub_Cover")
# Site Data
CameraData <- read_excel("C:/Users/DrewIvory/OneDrive - University of Florida/Desktop/School/PHD/01_Projects/04_Wildlife/02_Data/CameraData.xlsx")
CameraLoc <- read_excel("C:/Users/DrewIvory/OneDrive - University of Florida/Desktop/School/PHD/01_Projects/04_Wildlife/02_Data/CameraLoc.xlsx",
sheet = "CameraLocations")
# Add effort data
effort_matrix <- read_excel("C:/Users/DrewIvory/OneDrive - University of Florida/Desktop/School/PHD/01_Projects/04_Wildlife/02_Data/CameraLoc.xlsx",
sheet = "Effort_Matrix_Full") %>%
pivot_longer(cols = matches("^202[4-5]-"), names_to = "week", values_to = "days") %>%
filter(days == "7") %>%
dplyr::select(Plot, week)
I moved this from a later section because the filtering process removed quadrats that did not capture any species. Rows labeled as “None” were removed, suggesting that the number of quadrats sampled per plot is not consistent across all plots.
# Count the total number of quadrats per plot
quadrat_count <- Veg_Cover %>%
group_by(Plot) %>%
summarize(total_quadrats = n_distinct(Quadrat), .groups = "drop")
#Filter tree data to only include trees with "tree" in the growth column
tree_data <- dplyr::filter(tree_data, Growth == "Tree")
#Filter Veg Cover to exclude Shrubs and Trees
Veg_Cover <- dplyr::filter(Veg_Cover, Growth != "Shrub" & Growth != "Tree")
#Filter Shrub Cover to only include Shrubs and Trees
shrub_data <- dplyr::filter(shrub_data, Growth == "Shrub" | Growth == "Tree")
This is not needed for non-ordination analysis. Moving the threshold down to 0% to keep the option, but to ensure it has no effect for now.
# Calculate the total number of sites
total_sites <- nrow(CameraLoc)
# Function to filter data by frequency
filter_by_frequency <- function(df) {
# Group data by species and calculate the frequency
freq <- df %>%
group_by(Species) %>%
summarise(Frequency = n_distinct(Plot) / nrow(CameraLoc) * 100) %>%
filter(Frequency >= 0)
# Filter the original data to include only species with frequency >= 3%
filtered_df <- df %>%
filter(Species %in% freq$Species)
return(filtered_df)
}
# Filter tree data by frequency
tree_data <- filter_by_frequency(tree_data)
# Filter Veg Cover data by frequency
Veg_Cover <- filter_by_frequency(Veg_Cover)
# Filter Shrub Cover data by frequency
shrub_data <- filter_by_frequency(shrub_data)
# Total length of Shrub cover at a site
shrub_cover <- shrub_data %>%
mutate(Cover = Line_End - Line_Start) %>%
group_by(Species_Name, Plot) %>%
summarise(Shrub_Total_Cover = sum(Cover, na.rm = TRUE), .groups = "drop") %>%
mutate(Shrub_Percent_Cover = Shrub_Total_Cover / 3000 * 100)
# Summed length of shrub over at a site
shrub_cover_summed <- shrub_cover %>%
group_by(Plot) %>%
summarize(total_shrub_cover = sum(Shrub_Total_Cover, na.rm = TRUE), .groups = "drop")
# Combine Plot and Quadrat columns
Veg_Cover <- Veg_Cover %>%
mutate(Plot_Quadrat = paste(Plot, Quadrat, sep = '_'))
# Join with CogonSites to get site information
Veg_Cover <- Veg_Cover %>%
left_join(CameraLoc, by = "Plot")
# Sum species cover across quadrats for each species at each plot
veg_cover_summed <- Veg_Cover %>%
group_by(Plot, Species_Name) %>%
summarize(total_cover = sum(Cover_Per, na.rm = TRUE), .groups = "drop")
# Calculate average herbaceous species cover
avg_species_cover <- veg_cover_summed %>%
left_join(quadrat_count, by = "Plot") %>%
mutate(avg_cover = total_cover / total_quadrats)
This species matrix includes herbaceous and shrub species
# Merge shrub cover with herbaceous average cover
combined_cover <- avg_species_cover %>%
full_join(
shrub_cover %>%
dplyr::select(Plot, Species_Name, Shrub_Percent_Cover),
by = c("Plot", "Species_Name")
) %>%
mutate(
overlap_flag = ifelse(!is.na(avg_cover) & !is.na(Shrub_Percent_Cover), TRUE, FALSE), # Flag overlaps
final_cover = case_when(
!is.na(avg_cover) & is.na(Shrub_Percent_Cover) ~ avg_cover, # Use herbaceous cover if no shrub data
is.na(avg_cover) & !is.na(Shrub_Percent_Cover) ~ Shrub_Percent_Cover, # Use shrub cover if no herbaceous data
TRUE ~ NA_real_ # Leave as NA where overlaps exist
)
)
# Species Matrix
species_matrix <- combined_cover %>%
dplyr::select(Plot, Species_Name, final_cover) %>%
pivot_wider(
names_from = Species_Name,
values_from = final_cover,
values_fill = 0
)
avg_cogongrass_cover <- species_matrix %>%
group_by(Plot) %>%
summarize(Avg_Cogongrass_Cover = sum(Imperata_cylindrica, na.rm = TRUE) / n(), .groups = "drop")
# Summarize species cover by site
site_species_cover <- Veg_Cover %>%
group_by(Plot, Species_Name) %>%
summarize(total_cover = sum(Cover_Per, na.rm = TRUE)) %>%
ungroup()
## `summarise()` has grouped output by 'Plot'. You can override using the
## `.groups` argument.
## Remove all Imperata_cylindrica_Live and Imperata_cylindrica from species
site_species_cover <- site_species_cover %>%
filter(Species_Name != "Imperata_cylindrica_Live" & Species_Name != "Imperata_cylindrica")
# Calculate Shannon diversity per site
Veg_shannon_diversity <- site_species_cover %>%
group_by(Plot) %>%
mutate(proportion = total_cover / sum(total_cover)) %>%
summarize(Veg_shannon_index = -sum(proportion * log(proportion), na.rm = TRUE))
print(Veg_shannon_diversity)
## # A tibble: 206 × 2
## Plot Veg_shannon_index
## <chr> <dbl>
## 1 BI200 2.75
## 2 BI201 2.70
## 3 BI202 2.59
## 4 BI97 1.61
## 5 BI99 2.97
## 6 BN210 2.97
## 7 BN211 2.43
## 8 BN212 2.22
## 9 BN96 3.05
## 10 BN98 2.79
## # ℹ 196 more rows
if (!is.numeric(fuel_data$Height)) {
fuel_data$Height <- as.numeric(as.character(fuel_data$Height))
}
## Warning: NAs introduced by coercion
# Calculate average vegetation height per plot
veg_height <- fuel_data %>%
group_by(Plot) %>%
summarize(avg_veg_height = mean(Height, na.rm = TRUE), .groups = "drop")
# Tree density from point-centered quarter data
if (!is.numeric(tree_data$Distance)) {
tree_data$Distance <- as.numeric(as.character(tree_data$Distance))
}
tree_density_data <- tree_data %>%
group_by(Plot) %>%
summarize(Average_Distance = mean(Distance) / 100, # Convert to meters
Tree_Density = 10000 / (Average_Distance^2)) # Convert to trees per hectare
# Average canopy cover from vegetation quadrats
tree_canopy_data <- Veg_Cover %>%
distinct(Plot, Quadrat, .keep_all = TRUE) %>% # Ensure each quadrat counts once per plot
group_by(Plot) %>%
summarize(Avg_Canopy_Cover = mean(Canopy_Cover, na.rm = TRUE), .groups = "drop") # Calculate the average canopy cover per plot
cor(tree_density_data$Tree_Density, tree_canopy_data$Avg_Canopy_Cover)
## [1] 0.2742307
CameraLoc <- CameraLoc %>%
left_join(Veg_shannon_diversity, by = "Plot") %>%
left_join(avg_cogongrass_cover, by = "Plot") %>%
left_join(shrub_cover_summed %>% dplyr::select(Plot, total_shrub_cover), by = "Plot") %>%
left_join(veg_height, by = "Plot") %>%
left_join(tree_density_data %>% dplyr::select(Plot, Tree_Density), by = "Plot") %>%
left_join(tree_canopy_data %>% dplyr::select(Plot, Avg_Canopy_Cover), by = "Plot") %>%
dplyr::select(-Authority)
# Group by Name and count the number of observations
species_counts <- CameraData %>%
filter((Class == "Mammalia" & Name != "Odocoileus_virginianus") | Name == "Meleagris_gallopavo") %>%
group_by(Name) %>%
summarize(count = n(), .groups = "drop")
# Filter for species with count greater than 10
species_subset <- species_counts %>%
filter(count > 10) %>%
pull(Name)
# Filter CameraData to only include species with count > 10
CameraData <- CameraData %>%
filter(Name %in% species_subset)
# Format Data Weekly
observations_weekly <- CameraData %>%
group_by(Plot, week = format(as.Date(Date), "%Y-%U"), Name) %>%
summarise(observations = n(), .groups = 'drop')
# Merge with Effort Matrix to include only valid weeks
observations_weekly <- effort_matrix %>%
left_join(observations_weekly, by = c("Plot" = "Plot", "week")) %>%
replace_na(list(observations = 0))
# Convert to wide format
observations_species <- observations_weekly %>%
pivot_wider(names_from = Name, values_from = observations, values_fill = list(observations = 0)) %>%
dplyr::select(-"NA")
# Create detection array
site_names <- sort(unique(observations_species$Plot))
species_names <- setdiff(colnames(observations_species), c("Plot", "week"))
num_sites <- length(site_names)
num_weeks <- length(unique(observations_species$week))
num_species <- length(species_names)
detection_array <- array(0, dim = c(num_sites, num_weeks, num_species))
dimnames(detection_array) <- list(site_names, unique(observations_species$week), species_names)
for (s in seq_along(species_names)) {
species_col <- species_names[s]
for (i in seq_along(site_names)) {
site <- site_names[i]
for (j in seq_along(unique(observations_species$week))) {
week <- unique(observations_species$week)[j]
detection_array[i, j, s] <- ifelse(
any(observations_species$Plot == site & observations_species$week == week & observations_species[[species_col]] > 0),
1, 0
)
}
}
}
dim(detection_array) # Should be num_sites x num_weeks x num_species
## [1] 32 36 8
# Duplicate CameraLoc to be used in Objective 2
CameraLoc_O2 <- CameraLoc
# Standardize the covariates
CameraLoc <- CameraLoc %>%
dplyr::select(-Plot, -Camera, -Lat, -Long, -Status, - Start_Date)
covariates_matrix <- as.matrix(CameraLoc)
rownames(covariates_matrix) <- site_names
# Standardizing covariates
covariates_matrix <- scale(covariates_matrix)
## Correlation
cor_mat <- cor(covariates_matrix)
# Create week matrix for covariate structure [site x week]
week_vals <- unique(observations_species$week)
week_matrix <- matrix(rep(week_vals, each = num_sites), nrow = num_sites, ncol = num_weeks, byrow = FALSE)
# Create detection covariate list
det.covs <- list(
shrub_cover = covariates_matrix[, "total_shrub_cover"],
veg_height = covariates_matrix[, "avg_veg_height"],
week = week_matrix
)
# Remove dash and convert to numeric
week_numeric <- as.numeric(gsub("-", "", det.covs$week))
## Scale and center week_numeric
week_numeric <- scale(week_numeric)
# Reshape into the original 32x36 matrix
det.covs$week <- matrix(week_numeric, nrow = 32, ncol = 36)
str(det.covs)
## List of 3
## $ shrub_cover: Named num [1:32] 1.526 0.5 -0.153 -1.003 -0.811 ...
## ..- attr(*, "names")= chr [1:32] "BI201" "BN211" "EI100" "EI102" ...
## $ veg_height : Named num [1:32] 0.466 -1.044 1.181 0.879 1.684 ...
## ..- attr(*, "names")= chr [1:32] "BI201" "BN211" "EI100" "EI102" ...
## $ week : num [1:32, 1:36] -0.613 -0.613 -0.613 -0.613 -0.613 ...
This requires combining the presence data and the site covariate data into a single list. This also means that the presence data is in a 3-d format.
# Combine into a named list
data_list <- list(
y = detection_array,
occ.covs = covariates_matrix,
det.covs = det.covs
)
str(data_list)
## List of 3
## $ y : num [1:32, 1:36, 1:8] 0 0 0 0 0 0 0 0 0 0 ...
## ..- attr(*, "dimnames")=List of 3
## .. ..$ : chr [1:32] "BI201" "BN211" "EI100" "EI102" ...
## .. ..$ : chr [1:36] "2024-29" "2024-30" "2024-31" "2024-32" ...
## .. ..$ : chr [1:8] "Canis_latrans" "Procyon_lotor" "Dasypus_novemcinctus" "Lynx_rufus" ...
## $ occ.covs: num [1:32, 1:11] -0.237 -0.446 -0.337 -0.308 0.039 ...
## ..- attr(*, "dimnames")=List of 2
## .. ..$ : chr [1:32] "BI201" "BN211" "EI100" "EI102" ...
## .. ..$ : chr [1:11] "Cogon_Patch_Size" "VegetationDiversity" "PostTreatmentDensities" "Auth" ...
## ..- attr(*, "scaled:center")= Named num [1:11] 458.388 21.875 0.898 2.844 16.188 ...
## .. ..- attr(*, "names")= chr [1:11] "Cogon_Patch_Size" "VegetationDiversity" "PostTreatmentDensities" "Auth" ...
## ..- attr(*, "scaled:scale")= Named num [1:11] 1027.633 6.871 1.232 0.808 0.397 ...
## .. ..- attr(*, "names")= chr [1:11] "Cogon_Patch_Size" "VegetationDiversity" "PostTreatmentDensities" "Auth" ...
## $ det.covs:List of 3
## ..$ shrub_cover: Named num [1:32] 1.526 0.5 -0.153 -1.003 -0.811 ...
## .. ..- attr(*, "names")= chr [1:32] "BI201" "BN211" "EI100" "EI102" ...
## ..$ veg_height : Named num [1:32] 0.466 -1.044 1.181 0.879 1.684 ...
## .. ..- attr(*, "names")= chr [1:32] "BI201" "BN211" "EI100" "EI102" ...
## ..$ week : num [1:32, 1:36] -0.613 -0.613 -0.613 -0.613 -0.613 ...
I am unsure why I only had an issue with total shrub cover, but this should fix the “cannot find” issue.
# Convert occupancy and detection covariates to a dataframe
data_list[["occ.covs"]] <- as.data.frame(data_list[["occ.covs"]])
data_list[["occ.covs"]]$total_shrub_cover <- as.numeric(data_list[["occ.covs"]]$total_shrub_cover)
#data_list[["det.covs"]] <- as.data.frame(data_list[["det.covs"]])
#data_list[["det.covs"]]$total_shrub_cover <- as.numeric(data_list[["det.covs"]]$total_shrub_cover)
# Make species the first dimension
data_list$y <- aperm(data_list$y, c(3, 1, 2))
dimnames(data_list$y) <- list(species = dimnames(data_list$y)[[1]],
site = dimnames(data_list$y)[[2]],
week = dimnames(data_list$y)[[3]])
str(data_list)
## List of 3
## $ y : num [1:8, 1:32, 1:36] 0 0 0 0 0 0 0 0 0 0 ...
## ..- attr(*, "dimnames")=List of 3
## .. ..$ species: chr [1:8] "Canis_latrans" "Procyon_lotor" "Dasypus_novemcinctus" "Lynx_rufus" ...
## .. ..$ site : chr [1:32] "BI201" "BN211" "EI100" "EI102" ...
## .. ..$ week : chr [1:36] "2024-29" "2024-30" "2024-31" "2024-32" ...
## $ occ.covs:'data.frame': 32 obs. of 11 variables:
## ..$ Cogon_Patch_Size : num [1:32] -0.237 -0.446 -0.337 -0.308 0.039 ...
## ..$ VegetationDiversity : num [1:32] -0.273 0.455 1.619 -0.273 2.929 ...
## ..$ PostTreatmentDensities: num [1:32] 0.432 -0.729 0.432 2.169 1.13 ...
## ..$ Auth : num [1:32] -2.28 -2.28 -1.04 -1.04 -1.04 ...
## ..$ UTM_Zone : num [1:32] -0.473 -0.473 -0.473 -0.473 -0.473 ...
## ..$ Veg_shannon_index : num [1:32] 0.6829 0.0427 0.7279 -0.5991 1.1371 ...
## ..$ Avg_Cogongrass_Cover : num [1:32] -0.154 -0.708 0.308 2.045 1.121 ...
## ..$ total_shrub_cover : num [1:32] 1.526 0.5 -0.153 -1.003 -0.811 ...
## ..$ avg_veg_height : num [1:32] 0.466 -1.044 1.181 0.879 1.684 ...
## ..$ Tree_Density : num [1:32] -0.3629 -0.3564 -0.5111 3.5896 0.0958 ...
## ..$ Avg_Canopy_Cover : num [1:32] 0.1362 -0.0252 -0.9132 0.782 -1.9627 ...
## $ det.covs:List of 3
## ..$ shrub_cover: Named num [1:32] 1.526 0.5 -0.153 -1.003 -0.811 ...
## .. ..- attr(*, "names")= chr [1:32] "BI201" "BN211" "EI100" "EI102" ...
## ..$ veg_height : Named num [1:32] 0.466 -1.044 1.181 0.879 1.684 ...
## .. ..- attr(*, "names")= chr [1:32] "BI201" "BN211" "EI100" "EI102" ...
## ..$ week : num [1:32, 1:36] -0.613 -0.613 -0.613 -0.613 -0.613 ...
# Define detection formulas
det.null <- ~ 1
det.full <- ~ shrub_cover + veg_height + week
det.cover <- ~ shrub_cover + veg_height
det.week <- ~ week
det.week.quad <- ~ week + I(week^2)
det.full.quad <- ~ shrub_cover + veg_height + week + I(week^2)
# Define occupancy formulas
occ.null <- ~ 1
occ.full <- ~ Cogon_Patch_Size + Veg_shannon_index + total_shrub_cover + Avg_Cogongrass_Cover +
Tree_Density + Avg_Canopy_Cover + avg_veg_height + (1 | Auth)
occ.full.quad <- ~ Cogon_Patch_Size + Veg_shannon_index + total_shrub_cover + Avg_Cogongrass_Cover +
Tree_Density + Avg_Canopy_Cover + I(Avg_Cogongrass_Cover^2) + avg_veg_height + (1 | Auth)
occ.cover <- ~ Avg_Cogongrass_Cover + total_shrub_cover + avg_veg_height + (1 | Auth)
occ.canopy <- ~ Tree_Density + Avg_Canopy_Cover + (1 | Auth)
occ.move <- ~ Cogon_Patch_Size + Avg_Cogongrass_Cover + total_shrub_cover + (1 | Auth)
occ.forage <- ~ Veg_shannon_index + Avg_Cogongrass_Cover + (1 | Auth)
occ.cogon <- ~ Avg_Cogongrass_Cover + (1 | Auth)
occ.cogon.quad <- ~ Avg_Cogongrass_Cover + I(Avg_Cogongrass_Cover^2) + (1 | Auth)
ms_null_null <- msPGOcc(
occ.formula = occ.null,
det.formula = det.null,
data = data_list,
n.samples = 5000, # number of MCMC samples
n.thin = 2, # thinning parameter for the MCMC chain
n.burn = 3000, # burn-in period for the sampler
n.chains = 4, # number of MCMC chains
n.report = 500, # reporting interval for the sampler
)
## ----------------------------------------
## Preparing to run the model
## ----------------------------------------
## No prior specified for beta.comm.normal.
## Setting prior mean to 0 and prior variance to 2.72
## No prior specified for alpha.comm.normal.
## Setting prior mean to 0 and prior variance to 2.72
## No prior specified for tau.sq.beta.ig.
## Setting prior shape to 0.1 and prior scale to 0.1
## No prior specified for tau.sq.alpha.ig.
## Setting prior shape to 0.1 and prior scale to 0.1
## z is not specified in initial values.
## Setting initial values based on observed data
## beta.comm is not specified in initial values.
## Setting initial values to random values from the prior distribution
## alpha.comm is not specified in initial values.
## Setting initial values to random values from the prior distribution
## tau.sq.beta is not specified in initial values.
## Setting initial values to random values between 0.5 and 10
## tau.sq.alpha is not specified in initial values.
## Setting to initial values to random values between 0.5 and 10
## beta is not specified in initial values.
## Setting initial values to random values from the community-level normal distribution
## alpha is not specified in initial values.
## Setting initial values to random values from the community-level normal distribution
## ----------------------------------------
## Model description
## ----------------------------------------
## Multi-species Occupancy Model with Polya-Gamma latent
## variable fit with 32 sites and 8 species.
##
## Samples per Chain: 5000
## Burn-in: 3000
## Thinning Rate: 2
## Number of Chains: 4
## Total Posterior Samples: 4000
##
## Source compiled with OpenMP support and model fit using 1 thread(s).
##
## ----------------------------------------
## Chain 1
## ----------------------------------------
## Sampling ...
## Sampled: 500 of 5000, 10.00%
## -------------------------------------------------
## Sampled: 1000 of 5000, 20.00%
## -------------------------------------------------
## Sampled: 1500 of 5000, 30.00%
## -------------------------------------------------
## Sampled: 2000 of 5000, 40.00%
## -------------------------------------------------
## Sampled: 2500 of 5000, 50.00%
## -------------------------------------------------
## Sampled: 3000 of 5000, 60.00%
## -------------------------------------------------
## Sampled: 3500 of 5000, 70.00%
## -------------------------------------------------
## Sampled: 4000 of 5000, 80.00%
## -------------------------------------------------
## Sampled: 4500 of 5000, 90.00%
## -------------------------------------------------
## Sampled: 5000 of 5000, 100.00%
## ----------------------------------------
## Chain 2
## ----------------------------------------
## Sampling ...
## Sampled: 500 of 5000, 10.00%
## -------------------------------------------------
## Sampled: 1000 of 5000, 20.00%
## -------------------------------------------------
## Sampled: 1500 of 5000, 30.00%
## -------------------------------------------------
## Sampled: 2000 of 5000, 40.00%
## -------------------------------------------------
## Sampled: 2500 of 5000, 50.00%
## -------------------------------------------------
## Sampled: 3000 of 5000, 60.00%
## -------------------------------------------------
## Sampled: 3500 of 5000, 70.00%
## -------------------------------------------------
## Sampled: 4000 of 5000, 80.00%
## -------------------------------------------------
## Sampled: 4500 of 5000, 90.00%
## -------------------------------------------------
## Sampled: 5000 of 5000, 100.00%
## ----------------------------------------
## Chain 3
## ----------------------------------------
## Sampling ...
## Sampled: 500 of 5000, 10.00%
## -------------------------------------------------
## Sampled: 1000 of 5000, 20.00%
## -------------------------------------------------
## Sampled: 1500 of 5000, 30.00%
## -------------------------------------------------
## Sampled: 2000 of 5000, 40.00%
## -------------------------------------------------
## Sampled: 2500 of 5000, 50.00%
## -------------------------------------------------
## Sampled: 3000 of 5000, 60.00%
## -------------------------------------------------
## Sampled: 3500 of 5000, 70.00%
## -------------------------------------------------
## Sampled: 4000 of 5000, 80.00%
## -------------------------------------------------
## Sampled: 4500 of 5000, 90.00%
## -------------------------------------------------
## Sampled: 5000 of 5000, 100.00%
## ----------------------------------------
## Chain 4
## ----------------------------------------
## Sampling ...
## Sampled: 500 of 5000, 10.00%
## -------------------------------------------------
## Sampled: 1000 of 5000, 20.00%
## -------------------------------------------------
## Sampled: 1500 of 5000, 30.00%
## -------------------------------------------------
## Sampled: 2000 of 5000, 40.00%
## -------------------------------------------------
## Sampled: 2500 of 5000, 50.00%
## -------------------------------------------------
## Sampled: 3000 of 5000, 60.00%
## -------------------------------------------------
## Sampled: 3500 of 5000, 70.00%
## -------------------------------------------------
## Sampled: 4000 of 5000, 80.00%
## -------------------------------------------------
## Sampled: 4500 of 5000, 90.00%
## -------------------------------------------------
## Sampled: 5000 of 5000, 100.00%
summary(ms_null_null)
##
## Call:
## msPGOcc(occ.formula = occ.null, det.formula = det.null, data = data_list,
## n.samples = 5000, n.report = 500, n.burn = 3000, n.thin = 2,
## n.chains = 4)
##
## Samples per Chain: 5000
## Burn-in: 3000
## Thinning Rate: 2
## Number of Chains: 4
## Total Posterior Samples: 4000
## Run Time (min): 0.6758
##
## ----------------------------------------
## Community Level
## ----------------------------------------
## Occurrence Means (logit scale):
## Mean SD 2.5% 50% 97.5% Rhat ESS
## (Intercept) -0.3865 0.3237 -1.0253 -0.3834 0.2527 1.0011 2709
##
## Occurrence Variances (logit scale):
## Mean SD 2.5% 50% 97.5% Rhat ESS
## (Intercept) 0.684 0.6178 0.1112 0.5093 2.3113 1.0028 2410
##
## Detection Means (logit scale):
## Mean SD 2.5% 50% 97.5% Rhat ESS
## (Intercept) -2.5599 0.2777 -3.099 -2.5659 -1.9973 1.0002 3665
##
## Detection Variances (logit scale):
## Mean SD 2.5% 50% 97.5% Rhat ESS
## (Intercept) 0.5944 0.5369 0.1544 0.454 1.8946 1.0144 2884
##
## ----------------------------------------
## Species Level
## ----------------------------------------
## Occurrence (logit scale):
## Mean SD 2.5% 50% 97.5% Rhat
## (Intercept)-Canis_latrans 0.1523 0.3687 -0.5135 0.1422 0.9175 1.0007
## (Intercept)-Procyon_lotor 0.4832 0.3726 -0.2118 0.4730 1.2512 1.0047
## (Intercept)-Dasypus_novemcinctus -0.5923 0.3313 -1.2461 -0.5857 0.0342 1.0020
## (Intercept)-Lynx_rufus -0.1240 0.4681 -0.9801 -0.1533 0.9043 0.9998
## (Intercept)-Didelphis_virginiana -1.1401 0.4068 -1.9812 -1.1222 -0.3980 1.0028
## (Intercept)-Sylvilagus_floridanus -0.4112 0.4104 -1.2048 -0.4148 0.4158 1.0034
## (Intercept)-Meleagris_gallopavo -0.4131 0.4685 -1.2966 -0.4372 0.5868 1.0091
## (Intercept)-Sciurus_carolinensis -1.1183 0.4142 -1.9775 -1.0951 -0.3591 1.0060
## ESS
## (Intercept)-Canis_latrans 2848
## (Intercept)-Procyon_lotor 2939
## (Intercept)-Dasypus_novemcinctus 4000
## (Intercept)-Lynx_rufus 1427
## (Intercept)-Didelphis_virginiana 2833
## (Intercept)-Sylvilagus_floridanus 2035
## (Intercept)-Meleagris_gallopavo 1267
## (Intercept)-Sciurus_carolinensis 2347
##
## Detection (logit scale):
## Mean SD 2.5% 50% 97.5% Rhat
## (Intercept)-Canis_latrans -2.6097 0.1690 -2.9518 -2.6019 -2.2971 1.0015
## (Intercept)-Procyon_lotor -2.2650 0.1257 -2.5147 -2.2641 -2.0275 1.0080
## (Intercept)-Dasypus_novemcinctus -1.6074 0.1361 -1.8782 -1.6093 -1.3472 1.0012
## (Intercept)-Lynx_rufus -3.3510 0.2845 -3.9394 -3.3444 -2.8257 1.0023
## (Intercept)-Didelphis_virginiana -2.3537 0.2470 -2.8728 -2.3430 -1.8994 1.0069
## (Intercept)-Sylvilagus_floridanus -3.0954 0.2716 -3.6346 -3.0880 -2.5753 1.0086
## (Intercept)-Meleagris_gallopavo -3.2829 0.3107 -3.9214 -3.2715 -2.7111 1.0158
## (Intercept)-Sciurus_carolinensis -2.4601 0.2628 -3.0237 -2.4428 -1.9753 1.0064
## ESS
## (Intercept)-Canis_latrans 1338
## (Intercept)-Procyon_lotor 1933
## (Intercept)-Dasypus_novemcinctus 3215
## (Intercept)-Lynx_rufus 646
## (Intercept)-Didelphis_virginiana 1752
## (Intercept)-Sylvilagus_floridanus 827
## (Intercept)-Meleagris_gallopavo 651
## (Intercept)-Sciurus_carolinensis 1612
# Includes all covariates of detection and occupancy
ms_full_full <- msPGOcc(
occ.formula = occ.full,
det.formula = det.full,
data = data_list,
n.samples = 5000,
n.thin = 2,
n.burn = 3000,
n.chains = 4,
n.report = 500,
)
## ----------------------------------------
## Preparing to run the model
## ----------------------------------------
## Warning in (function (..., row.names = NULL, check.rows = FALSE, check.names =
## TRUE, : row names were found from a short variable and have been discarded
## No prior specified for beta.comm.normal.
## Setting prior mean to 0 and prior variance to 2.72
## No prior specified for alpha.comm.normal.
## Setting prior mean to 0 and prior variance to 2.72
## No prior specified for tau.sq.beta.ig.
## Setting prior shape to 0.1 and prior scale to 0.1
## No prior specified for tau.sq.alpha.ig.
## Setting prior shape to 0.1 and prior scale to 0.1
## No prior specified for sigma.sq.psi.ig.
## Setting prior shape to 0.1 and prior scale to 0.1
## z is not specified in initial values.
## Setting initial values based on observed data
## beta.comm is not specified in initial values.
## Setting initial values to random values from the prior distribution
## alpha.comm is not specified in initial values.
## Setting initial values to random values from the prior distribution
## tau.sq.beta is not specified in initial values.
## Setting initial values to random values between 0.5 and 10
## tau.sq.alpha is not specified in initial values.
## Setting to initial values to random values between 0.5 and 10
## beta is not specified in initial values.
## Setting initial values to random values from the community-level normal distribution
## alpha is not specified in initial values.
## Setting initial values to random values from the community-level normal distribution
## sigma.sq.psi is not specified in initial values.
## Setting initial values to random values between 0.5 and 10
## ----------------------------------------
## Model description
## ----------------------------------------
## Multi-species Occupancy Model with Polya-Gamma latent
## variable fit with 32 sites and 8 species.
##
## Samples per Chain: 5000
## Burn-in: 3000
## Thinning Rate: 2
## Number of Chains: 4
## Total Posterior Samples: 4000
##
## Source compiled with OpenMP support and model fit using 1 thread(s).
##
## ----------------------------------------
## Chain 1
## ----------------------------------------
## Sampling ...
## Sampled: 500 of 5000, 10.00%
## -------------------------------------------------
## Sampled: 1000 of 5000, 20.00%
## -------------------------------------------------
## Sampled: 1500 of 5000, 30.00%
## -------------------------------------------------
## Sampled: 2000 of 5000, 40.00%
## -------------------------------------------------
## Sampled: 2500 of 5000, 50.00%
## -------------------------------------------------
## Sampled: 3000 of 5000, 60.00%
## -------------------------------------------------
## Sampled: 3500 of 5000, 70.00%
## -------------------------------------------------
## Sampled: 4000 of 5000, 80.00%
## -------------------------------------------------
## Sampled: 4500 of 5000, 90.00%
## -------------------------------------------------
## Sampled: 5000 of 5000, 100.00%
## ----------------------------------------
## Chain 2
## ----------------------------------------
## Sampling ...
## Sampled: 500 of 5000, 10.00%
## -------------------------------------------------
## Sampled: 1000 of 5000, 20.00%
## -------------------------------------------------
## Sampled: 1500 of 5000, 30.00%
## -------------------------------------------------
## Sampled: 2000 of 5000, 40.00%
## -------------------------------------------------
## Sampled: 2500 of 5000, 50.00%
## -------------------------------------------------
## Sampled: 3000 of 5000, 60.00%
## -------------------------------------------------
## Sampled: 3500 of 5000, 70.00%
## -------------------------------------------------
## Sampled: 4000 of 5000, 80.00%
## -------------------------------------------------
## Sampled: 4500 of 5000, 90.00%
## -------------------------------------------------
## Sampled: 5000 of 5000, 100.00%
## ----------------------------------------
## Chain 3
## ----------------------------------------
## Sampling ...
## Sampled: 500 of 5000, 10.00%
## -------------------------------------------------
## Sampled: 1000 of 5000, 20.00%
## -------------------------------------------------
## Sampled: 1500 of 5000, 30.00%
## -------------------------------------------------
## Sampled: 2000 of 5000, 40.00%
## -------------------------------------------------
## Sampled: 2500 of 5000, 50.00%
## -------------------------------------------------
## Sampled: 3000 of 5000, 60.00%
## -------------------------------------------------
## Sampled: 3500 of 5000, 70.00%
## -------------------------------------------------
## Sampled: 4000 of 5000, 80.00%
## -------------------------------------------------
## Sampled: 4500 of 5000, 90.00%
## -------------------------------------------------
## Sampled: 5000 of 5000, 100.00%
## ----------------------------------------
## Chain 4
## ----------------------------------------
## Sampling ...
## Sampled: 500 of 5000, 10.00%
## -------------------------------------------------
## Sampled: 1000 of 5000, 20.00%
## -------------------------------------------------
## Sampled: 1500 of 5000, 30.00%
## -------------------------------------------------
## Sampled: 2000 of 5000, 40.00%
## -------------------------------------------------
## Sampled: 2500 of 5000, 50.00%
## -------------------------------------------------
## Sampled: 3000 of 5000, 60.00%
## -------------------------------------------------
## Sampled: 3500 of 5000, 70.00%
## -------------------------------------------------
## Sampled: 4000 of 5000, 80.00%
## -------------------------------------------------
## Sampled: 4500 of 5000, 90.00%
## -------------------------------------------------
## Sampled: 5000 of 5000, 100.00%
summary(ms_full_full)
##
## Call:
## msPGOcc(occ.formula = occ.full, det.formula = det.full, data = data_list,
## n.samples = 5000, n.report = 500, n.burn = 3000, n.thin = 2,
## n.chains = 4)
##
## Samples per Chain: 5000
## Burn-in: 3000
## Thinning Rate: 2
## Number of Chains: 4
## Total Posterior Samples: 4000
## Run Time (min): 1.0417
##
## ----------------------------------------
## Community Level
## ----------------------------------------
## Occurrence Means (logit scale):
## Mean SD 2.5% 50% 97.5% Rhat ESS
## (Intercept) -0.8272 0.6821 -2.1811 -0.8074 0.4656 1.0232 426
## Cogon_Patch_Size -0.4191 0.6375 -1.7381 -0.4269 0.8611 1.0083 658
## Veg_shannon_index 1.0399 0.4995 0.1268 1.0079 2.1424 1.0543 280
## total_shrub_cover -0.8883 0.6643 -2.2919 -0.8510 0.3027 1.0248 538
## Avg_Cogongrass_Cover 1.9407 0.7465 0.5120 1.9233 3.4134 1.0078 227
## Tree_Density -1.8897 0.8218 -3.5435 -1.8870 -0.2187 1.0104 632
## Avg_Canopy_Cover 1.8499 0.7438 0.4089 1.8141 3.4162 1.0058 954
## avg_veg_height -0.3749 0.5113 -1.3493 -0.3868 0.6730 1.0359 358
##
## Occurrence Variances (logit scale):
## Mean SD 2.5% 50% 97.5% Rhat ESS
## (Intercept) 2.2507 3.4374 0.0722 1.2889 10.1659 1.0479 559
## Cogon_Patch_Size 2.3286 3.4998 0.0890 1.1923 12.2531 1.0566 353
## Veg_shannon_index 0.6148 0.8813 0.0495 0.3339 2.9168 1.0075 968
## total_shrub_cover 2.3877 3.7308 0.0906 1.2382 11.9659 1.0650 326
## Avg_Cogongrass_Cover 1.1099 2.3840 0.0502 0.4459 6.5645 1.1089 330
## Tree_Density 3.8542 10.3378 0.0940 1.7878 19.4561 1.1729 565
## Avg_Canopy_Cover 4.5435 7.7270 0.2105 2.2223 23.9296 1.0479 231
## avg_veg_height 0.5571 0.8333 0.0452 0.2855 2.7066 1.0401 675
##
## Occurrence Random Effect Variances (logit scale):
## Mean SD 2.5% 50% 97.5% Rhat ESS
## Auth 2.8721 3.2993 0.1101 1.7851 12.5376 1.1996 90
##
## Detection Means (logit scale):
## Mean SD 2.5% 50% 97.5% Rhat ESS
## (Intercept) -2.7733 0.2994 -3.3647 -2.7794 -2.1445 1.0034 2518
## shrub_cover 0.3890 0.3128 -0.2236 0.3943 1.0199 1.0012 1446
## veg_height 0.0865 0.2100 -0.3256 0.0866 0.4986 1.0043 1290
## week -0.0995 0.1406 -0.3911 -0.0971 0.1696 1.0047 2169
##
## Detection Variances (logit scale):
## Mean SD 2.5% 50% 97.5% Rhat ESS
## (Intercept) 0.6602 0.5752 0.1575 0.5043 2.1149 1.0096 1974
## shrub_cover 0.6990 0.7086 0.1393 0.5129 2.3873 1.0280 1603
## veg_height 0.2718 0.2388 0.0627 0.2047 0.8458 1.0061 2029
## week 0.1079 0.1063 0.0244 0.0793 0.3646 1.0065 1803
##
## ----------------------------------------
## Species Level
## ----------------------------------------
## Occurrence (logit scale):
## Mean SD 2.5% 50%
## (Intercept)-Canis_latrans 0.0636 1.0036 -1.9037 0.0305
## (Intercept)-Procyon_lotor 0.0888 1.0361 -1.9936 0.1024
## (Intercept)-Dasypus_novemcinctus -1.2485 0.9188 -3.2693 -1.1650
## (Intercept)-Lynx_rufus -0.2387 1.3251 -2.5064 -0.3740
## (Intercept)-Didelphis_virginiana -1.8912 1.0372 -4.1081 -1.8080
## (Intercept)-Sylvilagus_floridanus -0.9644 0.9986 -2.9924 -0.9620
## (Intercept)-Meleagris_gallopavo -1.0170 1.1332 -3.4212 -0.9481
## (Intercept)-Sciurus_carolinensis -1.9506 1.1626 -4.5895 -1.8175
## Cogon_Patch_Size-Canis_latrans 0.5505 1.0513 -1.0534 0.3903
## Cogon_Patch_Size-Procyon_lotor -0.9612 0.7451 -2.5043 -0.9314
## Cogon_Patch_Size-Dasypus_novemcinctus -0.4465 0.7791 -1.9406 -0.4728
## Cogon_Patch_Size-Lynx_rufus -0.6668 1.2214 -3.0830 -0.6745
## Cogon_Patch_Size-Didelphis_virginiana 0.7679 0.9930 -0.7640 0.6293
## Cogon_Patch_Size-Sylvilagus_floridanus -1.5254 1.3956 -4.8078 -1.2869
## Cogon_Patch_Size-Meleagris_gallopavo -0.1325 1.2259 -2.1720 -0.2666
## Cogon_Patch_Size-Sciurus_carolinensis -1.2436 1.1895 -3.9744 -1.0685
## Veg_shannon_index-Canis_latrans 1.3374 0.6487 0.2578 1.2649
## Veg_shannon_index-Procyon_lotor 1.3110 0.6222 0.2376 1.2651
## Veg_shannon_index-Dasypus_novemcinctus 0.7253 0.5844 -0.4394 0.7311
## Veg_shannon_index-Lynx_rufus 0.9773 0.8004 -0.6381 0.9658
## Veg_shannon_index-Didelphis_virginiana 1.2064 0.6683 0.0616 1.1467
## Veg_shannon_index-Sylvilagus_floridanus 1.1402 0.7138 -0.1213 1.0856
## Veg_shannon_index-Meleagris_gallopavo 1.3395 0.7877 0.0240 1.2596
## Veg_shannon_index-Sciurus_carolinensis 0.4639 0.7737 -1.2417 0.5078
## total_shrub_cover-Canis_latrans 0.4929 0.9748 -1.0013 0.3369
## total_shrub_cover-Procyon_lotor -1.1402 0.6519 -2.5303 -1.0855
## total_shrub_cover-Dasypus_novemcinctus -0.3649 0.8198 -2.1009 -0.3378
## total_shrub_cover-Lynx_rufus -1.6477 1.3876 -5.0672 -1.3971
## total_shrub_cover-Didelphis_virginiana -1.1615 0.9965 -3.5604 -1.0197
## total_shrub_cover-Sylvilagus_floridanus -0.8781 1.1990 -3.4969 -0.8026
## total_shrub_cover-Meleagris_gallopavo -2.2239 1.4348 -5.6850 -1.9570
## total_shrub_cover-Sciurus_carolinensis -1.0039 1.1555 -3.7480 -0.8687
## Avg_Cogongrass_Cover-Canis_latrans 2.2720 0.8831 0.6721 2.2345
## Avg_Cogongrass_Cover-Procyon_lotor 2.0706 0.8816 0.4310 2.0379
## Avg_Cogongrass_Cover-Dasypus_novemcinctus 2.4759 0.9966 0.8154 2.3800
## Avg_Cogongrass_Cover-Lynx_rufus 2.2659 0.9926 0.5375 2.1976
## Avg_Cogongrass_Cover-Didelphis_virginiana 2.0095 0.9179 0.3262 1.9864
## Avg_Cogongrass_Cover-Sylvilagus_floridanus 1.3405 1.1171 -1.1296 1.4040
## Avg_Cogongrass_Cover-Meleagris_gallopavo 1.5660 1.3225 -1.5681 1.7073
## Avg_Cogongrass_Cover-Sciurus_carolinensis 2.1932 0.9508 0.4989 2.1374
## Tree_Density-Canis_latrans -2.7922 1.3330 -5.8613 -2.6051
## Tree_Density-Procyon_lotor -1.5019 0.8063 -3.1076 -1.5038
## Tree_Density-Dasypus_novemcinctus -3.7016 1.8600 -8.2314 -3.3129
## Tree_Density-Lynx_rufus -0.3287 1.2817 -2.5256 -0.4542
## Tree_Density-Didelphis_virginiana -2.1423 1.2844 -4.9717 -2.0763
## Tree_Density-Sylvilagus_floridanus -2.5945 1.5701 -6.1068 -2.3733
## Tree_Density-Meleagris_gallopavo -2.1956 1.5677 -5.4762 -2.1420
## Tree_Density-Sciurus_carolinensis -2.1808 1.5006 -5.5012 -2.0911
## Avg_Canopy_Cover-Canis_latrans 0.1725 0.6737 -1.1905 0.1760
## Avg_Canopy_Cover-Procyon_lotor 1.7409 0.7626 0.4213 1.6783
## Avg_Canopy_Cover-Dasypus_novemcinctus 2.3043 0.8783 0.9031 2.1815
## Avg_Canopy_Cover-Lynx_rufus 0.7664 1.3081 -1.8634 0.7445
## Avg_Canopy_Cover-Didelphis_virginiana 3.2180 1.4637 1.2319 2.9489
## Avg_Canopy_Cover-Sylvilagus_floridanus 3.9267 2.0170 1.2281 3.5415
## Avg_Canopy_Cover-Meleagris_gallopavo 2.5461 1.4639 0.5254 2.2638
## Avg_Canopy_Cover-Sciurus_carolinensis 3.0541 1.4657 1.0854 2.7411
## avg_veg_height-Canis_latrans -0.4408 0.6247 -1.6274 -0.4529
## avg_veg_height-Procyon_lotor -0.3597 0.5942 -1.5295 -0.3576
## avg_veg_height-Dasypus_novemcinctus -0.1347 0.6139 -1.2423 -0.1647
## avg_veg_height-Lynx_rufus -0.5697 0.7917 -2.2202 -0.5331
## avg_veg_height-Didelphis_virginiana -0.5818 0.7182 -2.0336 -0.5556
## avg_veg_height-Sylvilagus_floridanus -0.6223 0.7487 -2.1858 -0.5960
## avg_veg_height-Meleagris_gallopavo -0.4175 0.8604 -2.2391 -0.4245
## avg_veg_height-Sciurus_carolinensis 0.0334 0.7206 -1.2149 -0.0456
## 97.5% Rhat ESS
## (Intercept)-Canis_latrans 2.1118 1.0088 426
## (Intercept)-Procyon_lotor 2.0496 1.0561 249
## (Intercept)-Dasypus_novemcinctus 0.3691 1.0094 466
## (Intercept)-Lynx_rufus 2.9292 1.0261 216
## (Intercept)-Didelphis_virginiana -0.1157 1.0059 515
## (Intercept)-Sylvilagus_floridanus 1.1588 1.0215 565
## (Intercept)-Meleagris_gallopavo 1.2062 1.0027 466
## (Intercept)-Sciurus_carolinensis -0.0896 1.0095 365
## Cogon_Patch_Size-Canis_latrans 3.1623 1.0405 802
## Cogon_Patch_Size-Procyon_lotor 0.4370 1.0403 309
## Cogon_Patch_Size-Dasypus_novemcinctus 1.2078 1.0034 756
## Cogon_Patch_Size-Lynx_rufus 1.7159 1.0665 375
## Cogon_Patch_Size-Didelphis_virginiana 3.1744 1.0668 349
## Cogon_Patch_Size-Sylvilagus_floridanus 0.5276 1.0548 335
## Cogon_Patch_Size-Meleagris_gallopavo 2.6918 1.0194 484
## Cogon_Patch_Size-Sciurus_carolinensis 0.6003 1.0628 410
## Veg_shannon_index-Canis_latrans 2.8324 1.0175 362
## Veg_shannon_index-Procyon_lotor 2.6816 1.0615 308
## Veg_shannon_index-Dasypus_novemcinctus 1.8914 1.0170 449
## Veg_shannon_index-Lynx_rufus 2.5794 1.0452 312
## Veg_shannon_index-Didelphis_virginiana 2.6264 1.0164 502
## Veg_shannon_index-Sylvilagus_floridanus 2.7418 1.0487 473
## Veg_shannon_index-Meleagris_gallopavo 3.1786 1.0212 563
## Veg_shannon_index-Sciurus_carolinensis 1.9212 1.0592 474
## total_shrub_cover-Canis_latrans 2.8771 1.0389 366
## total_shrub_cover-Procyon_lotor -0.0041 1.0014 905
## total_shrub_cover-Dasypus_novemcinctus 1.1235 1.0233 574
## total_shrub_cover-Lynx_rufus 0.4588 1.0870 233
## total_shrub_cover-Didelphis_virginiana 0.4236 1.0193 540
## total_shrub_cover-Sylvilagus_floridanus 1.3954 1.0129 452
## total_shrub_cover-Meleagris_gallopavo -0.1713 1.0138 333
## total_shrub_cover-Sciurus_carolinensis 0.9121 1.0281 450
## Avg_Cogongrass_Cover-Canis_latrans 4.1569 1.0033 388
## Avg_Cogongrass_Cover-Procyon_lotor 3.9289 1.0072 357
## Avg_Cogongrass_Cover-Dasypus_novemcinctus 4.7706 1.0169 287
## Avg_Cogongrass_Cover-Lynx_rufus 4.4832 1.0111 389
## Avg_Cogongrass_Cover-Didelphis_virginiana 3.8461 1.0021 420
## Avg_Cogongrass_Cover-Sylvilagus_floridanus 3.3414 1.0222 316
## Avg_Cogongrass_Cover-Meleagris_gallopavo 3.7917 1.0209 238
## Avg_Cogongrass_Cover-Sciurus_carolinensis 4.1851 1.0129 294
## Tree_Density-Canis_latrans -0.7900 1.0073 573
## Tree_Density-Procyon_lotor 0.1417 1.0139 664
## Tree_Density-Dasypus_novemcinctus -1.3025 1.0137 284
## Tree_Density-Lynx_rufus 2.4646 1.0342 335
## Tree_Density-Didelphis_virginiana 0.4865 1.0076 562
## Tree_Density-Sylvilagus_floridanus -0.1664 1.0077 336
## Tree_Density-Meleagris_gallopavo 1.0809 1.0308 463
## Tree_Density-Sciurus_carolinensis 0.7221 1.0216 405
## Avg_Canopy_Cover-Canis_latrans 1.4560 1.0156 1065
## Avg_Canopy_Cover-Procyon_lotor 3.4657 1.0216 614
## Avg_Canopy_Cover-Dasypus_novemcinctus 4.3496 1.0156 294
## Avg_Canopy_Cover-Lynx_rufus 3.4667 1.0076 394
## Avg_Canopy_Cover-Didelphis_virginiana 6.8390 1.0370 252
## Avg_Canopy_Cover-Sylvilagus_floridanus 9.2183 1.0048 188
## Avg_Canopy_Cover-Meleagris_gallopavo 6.3086 1.0163 378
## Avg_Canopy_Cover-Sciurus_carolinensis 6.7128 1.0428 209
## avg_veg_height-Canis_latrans 0.8536 1.0258 494
## avg_veg_height-Procyon_lotor 0.8106 1.0183 739
## avg_veg_height-Dasypus_novemcinctus 1.1645 1.0271 553
## avg_veg_height-Lynx_rufus 0.9016 1.0167 500
## avg_veg_height-Didelphis_virginiana 0.7586 1.0123 681
## avg_veg_height-Sylvilagus_floridanus 0.8254 1.0151 506
## avg_veg_height-Meleagris_gallopavo 1.3312 1.0426 410
## avg_veg_height-Sciurus_carolinensis 1.6740 1.0490 724
##
## Detection (logit scale):
## Mean SD 2.5% 50% 97.5% Rhat
## (Intercept)-Canis_latrans -2.7585 0.1832 -3.1474 -2.7502 -2.4175 1.0116
## (Intercept)-Procyon_lotor -2.3015 0.1398 -2.5927 -2.2971 -2.0401 1.0026
## (Intercept)-Dasypus_novemcinctus -1.8288 0.1695 -2.1659 -1.8213 -1.5050 1.0036
## (Intercept)-Lynx_rufus -3.5473 0.3269 -4.2331 -3.5378 -2.9469 1.0167
## (Intercept)-Didelphis_virginiana -2.6608 0.2943 -3.2358 -2.6528 -2.1125 1.0072
## (Intercept)-Sylvilagus_floridanus -3.1731 0.2497 -3.6894 -3.1604 -2.7164 1.0004
## (Intercept)-Meleagris_gallopavo -3.6932 0.4215 -4.5346 -3.6794 -2.8605 1.0176
## (Intercept)-Sciurus_carolinensis -2.8058 0.3061 -3.3826 -2.8064 -2.2037 1.0027
## shrub_cover-Canis_latrans -0.3441 0.2290 -0.7806 -0.3435 0.1162 1.0080
## shrub_cover-Procyon_lotor 0.2753 0.1578 -0.0359 0.2786 0.5756 1.0079
## shrub_cover-Dasypus_novemcinctus 0.9894 0.3127 0.3679 0.9911 1.6044 1.0030
## shrub_cover-Lynx_rufus 0.0791 0.3860 -0.7056 0.0942 0.7938 1.0003
## shrub_cover-Didelphis_virginiana 1.0651 0.3804 0.3676 1.0497 1.8741 1.0115
## shrub_cover-Sylvilagus_floridanus 0.5525 0.4060 -0.2679 0.5570 1.3191 1.0046
## shrub_cover-Meleagris_gallopavo -0.4092 0.4241 -1.2448 -0.4151 0.4534 1.0132
## shrub_cover-Sciurus_carolinensis 1.0588 0.3981 0.2487 1.0652 1.8257 1.0179
## veg_height-Canis_latrans -0.5964 0.1852 -0.9830 -0.5918 -0.2476 1.0039
## veg_height-Procyon_lotor 0.3524 0.1250 0.1032 0.3543 0.5916 1.0013
## veg_height-Dasypus_novemcinctus 0.2815 0.1396 0.0069 0.2787 0.5661 1.0005
## veg_height-Lynx_rufus 0.0875 0.2476 -0.4105 0.0941 0.5441 1.0134
## veg_height-Didelphis_virginiana 0.4944 0.2423 0.0377 0.4849 0.9923 1.0054
## veg_height-Sylvilagus_floridanus 0.1615 0.2490 -0.3304 0.1667 0.6546 1.0032
## veg_height-Meleagris_gallopavo -0.2277 0.3979 -1.0100 -0.2241 0.5661 1.0138
## veg_height-Sciurus_carolinensis 0.1462 0.2260 -0.2835 0.1408 0.6021 1.0015
## week-Canis_latrans 0.0553 0.1333 -0.2182 0.0592 0.3000 1.0036
## week-Procyon_lotor -0.0616 0.1192 -0.3056 -0.0600 0.1563 1.0013
## week-Dasypus_novemcinctus -0.1788 0.1387 -0.4600 -0.1722 0.0839 1.0011
## week-Lynx_rufus -0.0476 0.1936 -0.4426 -0.0433 0.3241 1.0002
## week-Didelphis_virginiana -0.2290 0.2252 -0.7188 -0.2101 0.1718 1.0072
## week-Sylvilagus_floridanus -0.1662 0.2020 -0.5947 -0.1545 0.2003 1.0147
## week-Meleagris_gallopavo -0.2903 0.2417 -0.8145 -0.2686 0.1377 1.0023
## week-Sciurus_carolinensis 0.1186 0.1847 -0.2454 0.1198 0.4730 1.0047
## ESS
## (Intercept)-Canis_latrans 1034
## (Intercept)-Procyon_lotor 1584
## (Intercept)-Dasypus_novemcinctus 1441
## (Intercept)-Lynx_rufus 414
## (Intercept)-Didelphis_virginiana 644
## (Intercept)-Sylvilagus_floridanus 847
## (Intercept)-Meleagris_gallopavo 386
## (Intercept)-Sciurus_carolinensis 799
## shrub_cover-Canis_latrans 754
## shrub_cover-Procyon_lotor 2116
## shrub_cover-Dasypus_novemcinctus 957
## shrub_cover-Lynx_rufus 483
## shrub_cover-Didelphis_virginiana 471
## shrub_cover-Sylvilagus_floridanus 527
## shrub_cover-Meleagris_gallopavo 365
## shrub_cover-Sciurus_carolinensis 643
## veg_height-Canis_latrans 952
## veg_height-Procyon_lotor 1757
## veg_height-Dasypus_novemcinctus 2318
## veg_height-Lynx_rufus 750
## veg_height-Didelphis_virginiana 1224
## veg_height-Sylvilagus_floridanus 981
## veg_height-Meleagris_gallopavo 461
## veg_height-Sciurus_carolinensis 1182
## week-Canis_latrans 2159
## week-Procyon_lotor 2139
## week-Dasypus_novemcinctus 2531
## week-Lynx_rufus 1336
## week-Didelphis_virginiana 1599
## week-Sylvilagus_floridanus 1406
## week-Meleagris_gallopavo 1026
## week-Sciurus_carolinensis 2030
#Includes cover for detection and only foraging for occupancy
ms_cover_forage <- msPGOcc(
occ.formula = occ.forage,
det.formula = det.cover,
data = data_list,
n.samples = 5000,
n.thin = 2,
n.burn = 3000,
n.chains = 4,
n.report = 500,
)
## ----------------------------------------
## Preparing to run the model
## ----------------------------------------
## No prior specified for beta.comm.normal.
## Setting prior mean to 0 and prior variance to 2.72
## No prior specified for alpha.comm.normal.
## Setting prior mean to 0 and prior variance to 2.72
## No prior specified for tau.sq.beta.ig.
## Setting prior shape to 0.1 and prior scale to 0.1
## No prior specified for tau.sq.alpha.ig.
## Setting prior shape to 0.1 and prior scale to 0.1
## No prior specified for sigma.sq.psi.ig.
## Setting prior shape to 0.1 and prior scale to 0.1
## z is not specified in initial values.
## Setting initial values based on observed data
## beta.comm is not specified in initial values.
## Setting initial values to random values from the prior distribution
## alpha.comm is not specified in initial values.
## Setting initial values to random values from the prior distribution
## tau.sq.beta is not specified in initial values.
## Setting initial values to random values between 0.5 and 10
## tau.sq.alpha is not specified in initial values.
## Setting to initial values to random values between 0.5 and 10
## beta is not specified in initial values.
## Setting initial values to random values from the community-level normal distribution
## alpha is not specified in initial values.
## Setting initial values to random values from the community-level normal distribution
## sigma.sq.psi is not specified in initial values.
## Setting initial values to random values between 0.5 and 10
## ----------------------------------------
## Model description
## ----------------------------------------
## Multi-species Occupancy Model with Polya-Gamma latent
## variable fit with 32 sites and 8 species.
##
## Samples per Chain: 5000
## Burn-in: 3000
## Thinning Rate: 2
## Number of Chains: 4
## Total Posterior Samples: 4000
##
## Source compiled with OpenMP support and model fit using 1 thread(s).
##
## ----------------------------------------
## Chain 1
## ----------------------------------------
## Sampling ...
## Sampled: 500 of 5000, 10.00%
## -------------------------------------------------
## Sampled: 1000 of 5000, 20.00%
## -------------------------------------------------
## Sampled: 1500 of 5000, 30.00%
## -------------------------------------------------
## Sampled: 2000 of 5000, 40.00%
## -------------------------------------------------
## Sampled: 2500 of 5000, 50.00%
## -------------------------------------------------
## Sampled: 3000 of 5000, 60.00%
## -------------------------------------------------
## Sampled: 3500 of 5000, 70.00%
## -------------------------------------------------
## Sampled: 4000 of 5000, 80.00%
## -------------------------------------------------
## Sampled: 4500 of 5000, 90.00%
## -------------------------------------------------
## Sampled: 5000 of 5000, 100.00%
## ----------------------------------------
## Chain 2
## ----------------------------------------
## Sampling ...
## Sampled: 500 of 5000, 10.00%
## -------------------------------------------------
## Sampled: 1000 of 5000, 20.00%
## -------------------------------------------------
## Sampled: 1500 of 5000, 30.00%
## -------------------------------------------------
## Sampled: 2000 of 5000, 40.00%
## -------------------------------------------------
## Sampled: 2500 of 5000, 50.00%
## -------------------------------------------------
## Sampled: 3000 of 5000, 60.00%
## -------------------------------------------------
## Sampled: 3500 of 5000, 70.00%
## -------------------------------------------------
## Sampled: 4000 of 5000, 80.00%
## -------------------------------------------------
## Sampled: 4500 of 5000, 90.00%
## -------------------------------------------------
## Sampled: 5000 of 5000, 100.00%
## ----------------------------------------
## Chain 3
## ----------------------------------------
## Sampling ...
## Sampled: 500 of 5000, 10.00%
## -------------------------------------------------
## Sampled: 1000 of 5000, 20.00%
## -------------------------------------------------
## Sampled: 1500 of 5000, 30.00%
## -------------------------------------------------
## Sampled: 2000 of 5000, 40.00%
## -------------------------------------------------
## Sampled: 2500 of 5000, 50.00%
## -------------------------------------------------
## Sampled: 3000 of 5000, 60.00%
## -------------------------------------------------
## Sampled: 3500 of 5000, 70.00%
## -------------------------------------------------
## Sampled: 4000 of 5000, 80.00%
## -------------------------------------------------
## Sampled: 4500 of 5000, 90.00%
## -------------------------------------------------
## Sampled: 5000 of 5000, 100.00%
## ----------------------------------------
## Chain 4
## ----------------------------------------
## Sampling ...
## Sampled: 500 of 5000, 10.00%
## -------------------------------------------------
## Sampled: 1000 of 5000, 20.00%
## -------------------------------------------------
## Sampled: 1500 of 5000, 30.00%
## -------------------------------------------------
## Sampled: 2000 of 5000, 40.00%
## -------------------------------------------------
## Sampled: 2500 of 5000, 50.00%
## -------------------------------------------------
## Sampled: 3000 of 5000, 60.00%
## -------------------------------------------------
## Sampled: 3500 of 5000, 70.00%
## -------------------------------------------------
## Sampled: 4000 of 5000, 80.00%
## -------------------------------------------------
## Sampled: 4500 of 5000, 90.00%
## -------------------------------------------------
## Sampled: 5000 of 5000, 100.00%
summary(ms_cover_forage)
##
## Call:
## msPGOcc(occ.formula = occ.forage, det.formula = det.cover, data = data_list,
## n.samples = 5000, n.report = 500, n.burn = 3000, n.thin = 2,
## n.chains = 4)
##
## Samples per Chain: 5000
## Burn-in: 3000
## Thinning Rate: 2
## Number of Chains: 4
## Total Posterior Samples: 4000
## Run Time (min): 0.7455
##
## ----------------------------------------
## Community Level
## ----------------------------------------
## Occurrence Means (logit scale):
## Mean SD 2.5% 50% 97.5% Rhat ESS
## (Intercept) -0.3579 0.3871 -1.1081 -0.3626 0.3954 1.0160 595
## Veg_shannon_index 0.3751 0.2800 -0.1671 0.3683 0.9364 1.0052 1306
## Avg_Cogongrass_Cover 0.3511 0.2901 -0.2256 0.3575 0.9000 1.0105 1297
##
## Occurrence Variances (logit scale):
## Mean SD 2.5% 50% 97.5% Rhat ESS
## (Intercept) 0.6468 0.7918 0.0543 0.4149 2.6608 1.0023 1135
## Veg_shannon_index 0.3015 0.4581 0.0371 0.1867 1.2499 1.0637 1927
## Avg_Cogongrass_Cover 0.3363 0.5001 0.0386 0.2004 1.4381 1.0440 1496
##
## Occurrence Random Effect Variances (logit scale):
## Mean SD 2.5% 50% 97.5% Rhat ESS
## Auth 0.7624 0.6936 0.0626 0.572 2.4901 1.0475 321
##
## Detection Means (logit scale):
## Mean SD 2.5% 50% 97.5% Rhat ESS
## (Intercept) -2.7382 0.3262 -3.3736 -2.7426 -2.0770 1.0037 2475
## shrub_cover 0.2542 0.3157 -0.3683 0.2535 0.8937 1.0049 1914
## veg_height 0.0571 0.2017 -0.3615 0.0630 0.4413 1.0020 1700
##
## Detection Variances (logit scale):
## Mean SD 2.5% 50% 97.5% Rhat ESS
## (Intercept) 0.7773 0.7542 0.1819 0.5903 2.4836 1.0121 1386
## shrub_cover 0.7066 0.6865 0.1390 0.5314 2.2567 1.0114 1746
## veg_height 0.2595 0.2472 0.0546 0.1904 0.8805 1.0201 1663
##
## ----------------------------------------
## Species Level
## ----------------------------------------
## Occurrence (logit scale):
## Mean SD 2.5% 50%
## (Intercept)-Canis_latrans 0.0292 0.5428 -1.0025 0.0084
## (Intercept)-Procyon_lotor 0.1743 0.5799 -0.9529 0.1739
## (Intercept)-Dasypus_novemcinctus -0.5493 0.4811 -1.5290 -0.5354
## (Intercept)-Lynx_rufus -0.1840 0.6300 -1.3617 -0.2176
## (Intercept)-Didelphis_virginiana -0.9303 0.5648 -2.1519 -0.8962
## (Intercept)-Sylvilagus_floridanus -0.4141 0.5360 -1.4469 -0.4141
## (Intercept)-Meleagris_gallopavo -0.1303 0.7129 -1.3517 -0.2126
## (Intercept)-Sciurus_carolinensis -0.9205 0.5658 -2.1564 -0.8677
## Veg_shannon_index-Canis_latrans 0.6488 0.3877 -0.0556 0.6197
## Veg_shannon_index-Procyon_lotor 0.4661 0.3684 -0.2372 0.4508
## Veg_shannon_index-Dasypus_novemcinctus 0.1998 0.3508 -0.5339 0.2123
## Veg_shannon_index-Lynx_rufus 0.2357 0.4806 -0.8042 0.2511
## Veg_shannon_index-Didelphis_virginiana 0.4935 0.3747 -0.2206 0.4777
## Veg_shannon_index-Sylvilagus_floridanus 0.4456 0.4197 -0.3616 0.4390
## Veg_shannon_index-Meleagris_gallopavo 0.5279 0.4930 -0.3582 0.4893
## Veg_shannon_index-Sciurus_carolinensis -0.0067 0.4170 -0.9064 0.0248
## Avg_Cogongrass_Cover-Canis_latrans 0.5954 0.3962 -0.1199 0.5705
## Avg_Cogongrass_Cover-Procyon_lotor 0.3778 0.3765 -0.3386 0.3649
## Avg_Cogongrass_Cover-Dasypus_novemcinctus 0.4600 0.3403 -0.1849 0.4529
## Avg_Cogongrass_Cover-Lynx_rufus 0.5850 0.4287 -0.1843 0.5616
## Avg_Cogongrass_Cover-Didelphis_virginiana 0.4613 0.3790 -0.2491 0.4504
## Avg_Cogongrass_Cover-Sylvilagus_floridanus -0.0494 0.4608 -1.0705 -0.0164
## Avg_Cogongrass_Cover-Meleagris_gallopavo -0.0385 0.6251 -1.4654 0.0244
## Avg_Cogongrass_Cover-Sciurus_carolinensis 0.4345 0.3699 -0.3016 0.4393
## 97.5% Rhat ESS
## (Intercept)-Canis_latrans 1.1305 1.0077 891
## (Intercept)-Procyon_lotor 1.3206 1.0163 532
## (Intercept)-Dasypus_novemcinctus 0.3701 1.0072 1363
## (Intercept)-Lynx_rufus 1.1163 1.0143 682
## (Intercept)-Didelphis_virginiana 0.1034 1.0140 1250
## (Intercept)-Sylvilagus_floridanus 0.6379 1.0156 925
## (Intercept)-Meleagris_gallopavo 1.5036 1.0148 410
## (Intercept)-Sciurus_carolinensis 0.0737 1.0168 1253
## Veg_shannon_index-Canis_latrans 1.5053 1.0009 1975
## Veg_shannon_index-Procyon_lotor 1.2430 1.0146 1937
## Veg_shannon_index-Dasypus_novemcinctus 0.8695 1.0007 2500
## Veg_shannon_index-Lynx_rufus 1.1372 1.0071 1465
## Veg_shannon_index-Didelphis_virginiana 1.2674 1.0014 2182
## Veg_shannon_index-Sylvilagus_floridanus 1.3192 1.0044 1662
## Veg_shannon_index-Meleagris_gallopavo 1.6226 1.0039 1510
## Veg_shannon_index-Sciurus_carolinensis 0.7549 1.0005 1468
## Avg_Cogongrass_Cover-Canis_latrans 1.4303 1.0054 2237
## Avg_Cogongrass_Cover-Procyon_lotor 1.1546 1.0129 1888
## Avg_Cogongrass_Cover-Dasypus_novemcinctus 1.1689 1.0026 2462
## Avg_Cogongrass_Cover-Lynx_rufus 1.5175 1.0167 1741
## Avg_Cogongrass_Cover-Didelphis_virginiana 1.2426 1.0043 2050
## Avg_Cogongrass_Cover-Sylvilagus_floridanus 0.7656 1.0146 1254
## Avg_Cogongrass_Cover-Meleagris_gallopavo 1.0374 1.0075 717
## Avg_Cogongrass_Cover-Sciurus_carolinensis 1.1662 1.0085 2326
##
## Detection (logit scale):
## Mean SD 2.5% 50% 97.5% Rhat
## (Intercept)-Canis_latrans -2.7146 0.1829 -3.0939 -2.7127 -2.3729 1.0009
## (Intercept)-Procyon_lotor -2.2996 0.1453 -2.5969 -2.2958 -2.0321 1.0056
## (Intercept)-Dasypus_novemcinctus -1.7691 0.1637 -2.1076 -1.7607 -1.4661 1.0024
## (Intercept)-Lynx_rufus -3.5649 0.3315 -4.2424 -3.5597 -2.9345 1.0078
## (Intercept)-Didelphis_virginiana -2.5866 0.2834 -3.1926 -2.5707 -2.0682 1.0096
## (Intercept)-Sylvilagus_floridanus -3.1670 0.2814 -3.7790 -3.1492 -2.6564 1.0087
## (Intercept)-Meleagris_gallopavo -3.8538 0.4660 -4.7897 -3.8521 -2.9165 1.0425
## (Intercept)-Sciurus_carolinensis -2.6741 0.3044 -3.2883 -2.6641 -2.1237 1.0153
## shrub_cover-Canis_latrans -0.2818 0.2106 -0.7076 -0.2763 0.1188 1.0012
## shrub_cover-Procyon_lotor 0.2352 0.1716 -0.1206 0.2401 0.5490 1.0023
## shrub_cover-Dasypus_novemcinctus 0.8840 0.3068 0.2905 0.8788 1.5050 1.0076
## shrub_cover-Lynx_rufus -0.2346 0.3604 -0.9391 -0.2350 0.4878 1.0111
## shrub_cover-Didelphis_virginiana 0.9974 0.3827 0.3009 0.9809 1.8294 1.0067
## shrub_cover-Sylvilagus_floridanus 0.2572 0.4267 -0.5299 0.2337 1.1042 1.0107
## shrub_cover-Meleagris_gallopavo -0.6622 0.3913 -1.4597 -0.6601 0.1026 1.0277
## shrub_cover-Sciurus_carolinensis 0.8906 0.4068 0.0978 0.8800 1.7148 1.0036
## veg_height-Canis_latrans -0.5767 0.1868 -0.9645 -0.5654 -0.2326 1.0107
## veg_height-Procyon_lotor 0.3383 0.1250 0.0978 0.3363 0.5844 1.0094
## veg_height-Dasypus_novemcinctus 0.2558 0.1349 -0.0006 0.2537 0.5297 1.0018
## veg_height-Lynx_rufus 0.0120 0.2538 -0.5011 0.0143 0.5003 1.0031
## veg_height-Didelphis_virginiana 0.4387 0.2365 -0.0078 0.4307 0.9246 1.0066
## veg_height-Sylvilagus_floridanus 0.1350 0.2479 -0.3543 0.1343 0.6239 1.0125
## veg_height-Meleagris_gallopavo -0.2055 0.4089 -1.0520 -0.1921 0.5807 1.0032
## veg_height-Sciurus_carolinensis 0.0898 0.2183 -0.3322 0.0870 0.5302 1.0016
## ESS
## (Intercept)-Canis_latrans 981
## (Intercept)-Procyon_lotor 1528
## (Intercept)-Dasypus_novemcinctus 1503
## (Intercept)-Lynx_rufus 480
## (Intercept)-Didelphis_virginiana 925
## (Intercept)-Sylvilagus_floridanus 674
## (Intercept)-Meleagris_gallopavo 286
## (Intercept)-Sciurus_carolinensis 1085
## shrub_cover-Canis_latrans 1438
## shrub_cover-Procyon_lotor 1681
## shrub_cover-Dasypus_novemcinctus 1612
## shrub_cover-Lynx_rufus 581
## shrub_cover-Didelphis_virginiana 744
## shrub_cover-Sylvilagus_floridanus 619
## shrub_cover-Meleagris_gallopavo 394
## shrub_cover-Sciurus_carolinensis 992
## veg_height-Canis_latrans 996
## veg_height-Procyon_lotor 2244
## veg_height-Dasypus_novemcinctus 2633
## veg_height-Lynx_rufus 960
## veg_height-Didelphis_virginiana 1604
## veg_height-Sylvilagus_floridanus 1098
## veg_height-Meleagris_gallopavo 486
## veg_height-Sciurus_carolinensis 1577
# Includes movement covariates of occupancy and cover for detection
ms_cover_move <- msPGOcc(
occ.formula = occ.move,
det.formula = det.cover,
data = data_list,
n.samples = 5000,
n.thin = 2,
n.burn = 3000,
n.chains = 4,
n.report = 500,
)
## ----------------------------------------
## Preparing to run the model
## ----------------------------------------
## No prior specified for beta.comm.normal.
## Setting prior mean to 0 and prior variance to 2.72
## No prior specified for alpha.comm.normal.
## Setting prior mean to 0 and prior variance to 2.72
## No prior specified for tau.sq.beta.ig.
## Setting prior shape to 0.1 and prior scale to 0.1
## No prior specified for tau.sq.alpha.ig.
## Setting prior shape to 0.1 and prior scale to 0.1
## No prior specified for sigma.sq.psi.ig.
## Setting prior shape to 0.1 and prior scale to 0.1
## z is not specified in initial values.
## Setting initial values based on observed data
## beta.comm is not specified in initial values.
## Setting initial values to random values from the prior distribution
## alpha.comm is not specified in initial values.
## Setting initial values to random values from the prior distribution
## tau.sq.beta is not specified in initial values.
## Setting initial values to random values between 0.5 and 10
## tau.sq.alpha is not specified in initial values.
## Setting to initial values to random values between 0.5 and 10
## beta is not specified in initial values.
## Setting initial values to random values from the community-level normal distribution
## alpha is not specified in initial values.
## Setting initial values to random values from the community-level normal distribution
## sigma.sq.psi is not specified in initial values.
## Setting initial values to random values between 0.5 and 10
## ----------------------------------------
## Model description
## ----------------------------------------
## Multi-species Occupancy Model with Polya-Gamma latent
## variable fit with 32 sites and 8 species.
##
## Samples per Chain: 5000
## Burn-in: 3000
## Thinning Rate: 2
## Number of Chains: 4
## Total Posterior Samples: 4000
##
## Source compiled with OpenMP support and model fit using 1 thread(s).
##
## ----------------------------------------
## Chain 1
## ----------------------------------------
## Sampling ...
## Sampled: 500 of 5000, 10.00%
## -------------------------------------------------
## Sampled: 1000 of 5000, 20.00%
## -------------------------------------------------
## Sampled: 1500 of 5000, 30.00%
## -------------------------------------------------
## Sampled: 2000 of 5000, 40.00%
## -------------------------------------------------
## Sampled: 2500 of 5000, 50.00%
## -------------------------------------------------
## Sampled: 3000 of 5000, 60.00%
## -------------------------------------------------
## Sampled: 3500 of 5000, 70.00%
## -------------------------------------------------
## Sampled: 4000 of 5000, 80.00%
## -------------------------------------------------
## Sampled: 4500 of 5000, 90.00%
## -------------------------------------------------
## Sampled: 5000 of 5000, 100.00%
## ----------------------------------------
## Chain 2
## ----------------------------------------
## Sampling ...
## Sampled: 500 of 5000, 10.00%
## -------------------------------------------------
## Sampled: 1000 of 5000, 20.00%
## -------------------------------------------------
## Sampled: 1500 of 5000, 30.00%
## -------------------------------------------------
## Sampled: 2000 of 5000, 40.00%
## -------------------------------------------------
## Sampled: 2500 of 5000, 50.00%
## -------------------------------------------------
## Sampled: 3000 of 5000, 60.00%
## -------------------------------------------------
## Sampled: 3500 of 5000, 70.00%
## -------------------------------------------------
## Sampled: 4000 of 5000, 80.00%
## -------------------------------------------------
## Sampled: 4500 of 5000, 90.00%
## -------------------------------------------------
## Sampled: 5000 of 5000, 100.00%
## ----------------------------------------
## Chain 3
## ----------------------------------------
## Sampling ...
## Sampled: 500 of 5000, 10.00%
## -------------------------------------------------
## Sampled: 1000 of 5000, 20.00%
## -------------------------------------------------
## Sampled: 1500 of 5000, 30.00%
## -------------------------------------------------
## Sampled: 2000 of 5000, 40.00%
## -------------------------------------------------
## Sampled: 2500 of 5000, 50.00%
## -------------------------------------------------
## Sampled: 3000 of 5000, 60.00%
## -------------------------------------------------
## Sampled: 3500 of 5000, 70.00%
## -------------------------------------------------
## Sampled: 4000 of 5000, 80.00%
## -------------------------------------------------
## Sampled: 4500 of 5000, 90.00%
## -------------------------------------------------
## Sampled: 5000 of 5000, 100.00%
## ----------------------------------------
## Chain 4
## ----------------------------------------
## Sampling ...
## Sampled: 500 of 5000, 10.00%
## -------------------------------------------------
## Sampled: 1000 of 5000, 20.00%
## -------------------------------------------------
## Sampled: 1500 of 5000, 30.00%
## -------------------------------------------------
## Sampled: 2000 of 5000, 40.00%
## -------------------------------------------------
## Sampled: 2500 of 5000, 50.00%
## -------------------------------------------------
## Sampled: 3000 of 5000, 60.00%
## -------------------------------------------------
## Sampled: 3500 of 5000, 70.00%
## -------------------------------------------------
## Sampled: 4000 of 5000, 80.00%
## -------------------------------------------------
## Sampled: 4500 of 5000, 90.00%
## -------------------------------------------------
## Sampled: 5000 of 5000, 100.00%
summary(ms_cover_move)
##
## Call:
## msPGOcc(occ.formula = occ.move, det.formula = det.cover, data = data_list,
## n.samples = 5000, n.report = 500, n.burn = 3000, n.thin = 2,
## n.chains = 4)
##
## Samples per Chain: 5000
## Burn-in: 3000
## Thinning Rate: 2
## Number of Chains: 4
## Total Posterior Samples: 4000
## Run Time (min): 0.7748
##
## ----------------------------------------
## Community Level
## ----------------------------------------
## Occurrence Means (logit scale):
## Mean SD 2.5% 50% 97.5% Rhat ESS
## (Intercept) -0.2341 0.4447 -1.1265 -0.2418 0.6742 1.0087 510
## Cogon_Patch_Size 0.0084 0.4028 -0.8245 0.0207 0.8061 1.0088 1237
## Avg_Cogongrass_Cover 0.1100 0.3616 -0.5727 0.1007 0.8478 1.0066 803
## total_shrub_cover -0.9208 0.4738 -2.0043 -0.8698 -0.1217 1.0036 370
##
## Occurrence Variances (logit scale):
## Mean SD 2.5% 50% 97.5% Rhat ESS
## (Intercept) 0.7226 0.9588 0.0515 0.4277 3.2309 1.0046 1083
## Cogon_Patch_Size 0.7763 1.2112 0.0534 0.4154 3.6767 1.0269 964
## Avg_Cogongrass_Cover 0.4647 0.6818 0.0437 0.2639 2.1706 1.0109 1156
## total_shrub_cover 0.9228 1.3381 0.0696 0.5339 3.8652 1.0356 653
##
## Occurrence Random Effect Variances (logit scale):
## Mean SD 2.5% 50% 97.5% Rhat ESS
## Auth 1.3306 1.3083 0.0853 0.9598 4.9986 1.0096 173
##
## Detection Means (logit scale):
## Mean SD 2.5% 50% 97.5% Rhat ESS
## (Intercept) -2.7350 0.2831 -3.2785 -2.7361 -2.1759 1.0017 1580
## shrub_cover 0.5274 0.3148 -0.0822 0.5250 1.1839 1.0085 1162
## veg_height 0.0839 0.2050 -0.3277 0.0827 0.4792 1.0072 1564
##
## Detection Variances (logit scale):
## Mean SD 2.5% 50% 97.5% Rhat ESS
## (Intercept) 0.5490 0.5064 0.1200 0.4134 1.8053 1.0197 1777
## shrub_cover 0.6823 0.6597 0.1267 0.5066 2.2729 1.0072 1271
## veg_height 0.2511 0.2227 0.0567 0.1919 0.8102 1.0025 2129
##
## ----------------------------------------
## Species Level
## ----------------------------------------
## Occurrence (logit scale):
## Mean SD 2.5% 50%
## (Intercept)-Canis_latrans 0.2218 0.6272 -0.9116 0.1777
## (Intercept)-Procyon_lotor 0.3370 0.6690 -0.8889 0.2938
## (Intercept)-Dasypus_novemcinctus -0.3562 0.5749 -1.4966 -0.3648
## (Intercept)-Lynx_rufus -0.2047 0.6669 -1.5400 -0.2185
## (Intercept)-Didelphis_virginiana -0.6712 0.6342 -1.9795 -0.6401
## (Intercept)-Sylvilagus_floridanus -0.1022 0.6903 -1.3486 -0.1398
## (Intercept)-Meleagris_gallopavo -0.4948 0.6772 -1.9306 -0.4792
## (Intercept)-Sciurus_carolinensis -0.6829 0.7048 -2.1668 -0.6446
## Cogon_Patch_Size-Canis_latrans 0.6635 0.6652 -0.3435 0.5555
## Cogon_Patch_Size-Procyon_lotor -0.1401 0.4554 -1.0476 -0.1289
## Cogon_Patch_Size-Dasypus_novemcinctus 0.0267 0.4513 -0.8730 0.0327
## Cogon_Patch_Size-Lynx_rufus -0.0297 0.7199 -1.3688 -0.0688
## Cogon_Patch_Size-Didelphis_virginiana 0.5901 0.5068 -0.3014 0.5500
## Cogon_Patch_Size-Sylvilagus_floridanus -0.6443 0.8292 -2.5716 -0.5007
## Cogon_Patch_Size-Meleagris_gallopavo 0.0561 0.6096 -1.1328 0.0482
## Cogon_Patch_Size-Sciurus_carolinensis -0.4762 0.6385 -2.0422 -0.3878
## Avg_Cogongrass_Cover-Canis_latrans 0.2878 0.4521 -0.5318 0.2653
## Avg_Cogongrass_Cover-Procyon_lotor 0.0649 0.4615 -0.8313 0.0630
## Avg_Cogongrass_Cover-Dasypus_novemcinctus 0.3120 0.4290 -0.4958 0.2867
## Avg_Cogongrass_Cover-Lynx_rufus 0.4661 0.5341 -0.4295 0.4157
## Avg_Cogongrass_Cover-Didelphis_virginiana 0.0787 0.4814 -0.8733 0.0860
## Avg_Cogongrass_Cover-Sylvilagus_floridanus -0.2434 0.5771 -1.4718 -0.1945
## Avg_Cogongrass_Cover-Meleagris_gallopavo -0.4499 0.7163 -2.0595 -0.3805
## Avg_Cogongrass_Cover-Sciurus_carolinensis 0.3308 0.4864 -0.5845 0.3060
## total_shrub_cover-Canis_latrans 0.0140 0.6512 -1.0985 -0.0525
## total_shrub_cover-Procyon_lotor -1.2108 0.5911 -2.6023 -1.1390
## total_shrub_cover-Dasypus_novemcinctus -0.5665 0.6404 -2.0669 -0.4824
## total_shrub_cover-Lynx_rufus -1.3473 0.8373 -3.3364 -1.2272
## total_shrub_cover-Didelphis_virginiana -0.9303 0.6323 -2.4194 -0.8623
## total_shrub_cover-Sylvilagus_floridanus -1.2667 0.8472 -3.2630 -1.1345
## total_shrub_cover-Meleagris_gallopavo -1.5446 0.7764 -3.3858 -1.4380
## total_shrub_cover-Sciurus_carolinensis -0.8787 0.7859 -2.7627 -0.7828
## 97.5% Rhat ESS
## (Intercept)-Canis_latrans 1.6065 1.0008 782
## (Intercept)-Procyon_lotor 1.7948 1.0096 652
## (Intercept)-Dasypus_novemcinctus 0.8072 1.0078 692
## (Intercept)-Lynx_rufus 1.2139 1.0146 767
## (Intercept)-Didelphis_virginiana 0.5121 1.0104 645
## (Intercept)-Sylvilagus_floridanus 1.4086 1.0103 664
## (Intercept)-Meleagris_gallopavo 0.8252 1.0127 658
## (Intercept)-Sciurus_carolinensis 0.6412 1.0033 494
## Cogon_Patch_Size-Canis_latrans 2.3535 1.0098 1304
## Cogon_Patch_Size-Procyon_lotor 0.7473 1.0068 1482
## Cogon_Patch_Size-Dasypus_novemcinctus 0.9194 1.0077 1653
## Cogon_Patch_Size-Lynx_rufus 1.5157 1.0087 1005
## Cogon_Patch_Size-Didelphis_virginiana 1.7127 1.0036 1170
## Cogon_Patch_Size-Sylvilagus_floridanus 0.5723 1.0356 709
## Cogon_Patch_Size-Meleagris_gallopavo 1.3169 1.0031 1349
## Cogon_Patch_Size-Sciurus_carolinensis 0.5396 1.0165 1059
## Avg_Cogongrass_Cover-Canis_latrans 1.2422 1.0033 1183
## Avg_Cogongrass_Cover-Procyon_lotor 1.0017 1.0001 1450
## Avg_Cogongrass_Cover-Dasypus_novemcinctus 1.2173 1.0020 1353
## Avg_Cogongrass_Cover-Lynx_rufus 1.6855 1.0149 1085
## Avg_Cogongrass_Cover-Didelphis_virginiana 1.0265 0.9999 1357
## Avg_Cogongrass_Cover-Sylvilagus_floridanus 0.8188 1.0245 811
## Avg_Cogongrass_Cover-Meleagris_gallopavo 0.8080 1.0061 648
## Avg_Cogongrass_Cover-Sciurus_carolinensis 1.3403 1.0053 1088
## total_shrub_cover-Canis_latrans 1.4756 1.0107 691
## total_shrub_cover-Procyon_lotor -0.2426 1.0050 707
## total_shrub_cover-Dasypus_novemcinctus 0.5035 1.0033 484
## total_shrub_cover-Lynx_rufus -0.0217 1.0122 434
## total_shrub_cover-Didelphis_virginiana 0.1358 1.0016 621
## total_shrub_cover-Sylvilagus_floridanus 0.0199 1.0041 326
## total_shrub_cover-Meleagris_gallopavo -0.2985 1.0207 651
## total_shrub_cover-Sciurus_carolinensis 0.3691 1.0100 343
##
## Detection (logit scale):
## Mean SD 2.5% 50% 97.5% Rhat
## (Intercept)-Canis_latrans -2.7476 0.1853 -3.1268 -2.7443 -2.4021 1.0024
## (Intercept)-Procyon_lotor -2.3066 0.1376 -2.5774 -2.3037 -2.0438 1.0078
## (Intercept)-Dasypus_novemcinctus -1.8526 0.1832 -2.2293 -1.8473 -1.5149 1.0051
## (Intercept)-Lynx_rufus -3.3845 0.3107 -4.0278 -3.3630 -2.8180 1.0145
## (Intercept)-Didelphis_virginiana -2.6900 0.3031 -3.3135 -2.6834 -2.1228 1.0020
## (Intercept)-Sylvilagus_floridanus -3.2282 0.2596 -3.7664 -3.2189 -2.7320 1.0110
## (Intercept)-Meleagris_gallopavo -3.3863 0.4732 -4.4042 -3.3585 -2.5256 1.0165
## (Intercept)-Sciurus_carolinensis -2.8185 0.3388 -3.5297 -2.8071 -2.1909 1.0032
## shrub_cover-Canis_latrans -0.2612 0.2359 -0.7251 -0.2584 0.1989 1.0231
## shrub_cover-Procyon_lotor 0.3256 0.1605 0.0111 0.3277 0.6362 1.0036
## shrub_cover-Dasypus_novemcinctus 1.0866 0.3526 0.4277 1.0788 1.7977 1.0026
## shrub_cover-Lynx_rufus 0.2127 0.3559 -0.5353 0.2396 0.8593 1.0538
## shrub_cover-Didelphis_virginiana 1.1838 0.4131 0.4539 1.1553 2.0667 1.0120
## shrub_cover-Sylvilagus_floridanus 0.7979 0.4062 -0.0217 0.7997 1.5940 1.0181
## shrub_cover-Meleagris_gallopavo -0.1958 0.4424 -1.0933 -0.1894 0.6356 1.0240
## shrub_cover-Sciurus_carolinensis 1.1458 0.4154 0.3249 1.1383 1.9632 1.0050
## veg_height-Canis_latrans -0.5748 0.1829 -0.9392 -0.5700 -0.2315 1.0014
## veg_height-Procyon_lotor 0.3515 0.1229 0.1020 0.3511 0.5910 1.0077
## veg_height-Dasypus_novemcinctus 0.2804 0.1391 0.0110 0.2788 0.5556 1.0016
## veg_height-Lynx_rufus 0.0487 0.2355 -0.4279 0.0552 0.4901 1.0252
## veg_height-Didelphis_virginiana 0.4479 0.2521 -0.0147 0.4399 0.9617 1.0106
## veg_height-Sylvilagus_floridanus 0.0724 0.2364 -0.3841 0.0735 0.5437 1.0170
## veg_height-Meleagris_gallopavo -0.0817 0.4183 -0.8684 -0.0982 0.7958 1.0100
## veg_height-Sciurus_carolinensis 0.1463 0.2287 -0.2872 0.1437 0.6200 1.0043
## ESS
## (Intercept)-Canis_latrans 958
## (Intercept)-Procyon_lotor 2209
## (Intercept)-Dasypus_novemcinctus 869
## (Intercept)-Lynx_rufus 583
## (Intercept)-Didelphis_virginiana 594
## (Intercept)-Sylvilagus_floridanus 597
## (Intercept)-Meleagris_gallopavo 488
## (Intercept)-Sciurus_carolinensis 483
## shrub_cover-Canis_latrans 783
## shrub_cover-Procyon_lotor 1970
## shrub_cover-Dasypus_novemcinctus 608
## shrub_cover-Lynx_rufus 562
## shrub_cover-Didelphis_virginiana 491
## shrub_cover-Sylvilagus_floridanus 357
## shrub_cover-Meleagris_gallopavo 544
## shrub_cover-Sciurus_carolinensis 446
## veg_height-Canis_latrans 892
## veg_height-Procyon_lotor 2094
## veg_height-Dasypus_novemcinctus 2315
## veg_height-Lynx_rufus 992
## veg_height-Didelphis_virginiana 1178
## veg_height-Sylvilagus_floridanus 862
## veg_height-Meleagris_gallopavo 607
## veg_height-Sciurus_carolinensis 934
#Includes cover covariate of detection and only canopy for occupancy
ms_cover_canopy <- msPGOcc(
occ.formula = occ.canopy,
det.formula = det.cover,
data = data_list,
n.samples = 5000,
n.thin = 2,
n.burn = 3000,
n.chains = 4,
n.report = 500,
)
## ----------------------------------------
## Preparing to run the model
## ----------------------------------------
## No prior specified for beta.comm.normal.
## Setting prior mean to 0 and prior variance to 2.72
## No prior specified for alpha.comm.normal.
## Setting prior mean to 0 and prior variance to 2.72
## No prior specified for tau.sq.beta.ig.
## Setting prior shape to 0.1 and prior scale to 0.1
## No prior specified for tau.sq.alpha.ig.
## Setting prior shape to 0.1 and prior scale to 0.1
## No prior specified for sigma.sq.psi.ig.
## Setting prior shape to 0.1 and prior scale to 0.1
## z is not specified in initial values.
## Setting initial values based on observed data
## beta.comm is not specified in initial values.
## Setting initial values to random values from the prior distribution
## alpha.comm is not specified in initial values.
## Setting initial values to random values from the prior distribution
## tau.sq.beta is not specified in initial values.
## Setting initial values to random values between 0.5 and 10
## tau.sq.alpha is not specified in initial values.
## Setting to initial values to random values between 0.5 and 10
## beta is not specified in initial values.
## Setting initial values to random values from the community-level normal distribution
## alpha is not specified in initial values.
## Setting initial values to random values from the community-level normal distribution
## sigma.sq.psi is not specified in initial values.
## Setting initial values to random values between 0.5 and 10
## ----------------------------------------
## Model description
## ----------------------------------------
## Multi-species Occupancy Model with Polya-Gamma latent
## variable fit with 32 sites and 8 species.
##
## Samples per Chain: 5000
## Burn-in: 3000
## Thinning Rate: 2
## Number of Chains: 4
## Total Posterior Samples: 4000
##
## Source compiled with OpenMP support and model fit using 1 thread(s).
##
## ----------------------------------------
## Chain 1
## ----------------------------------------
## Sampling ...
## Sampled: 500 of 5000, 10.00%
## -------------------------------------------------
## Sampled: 1000 of 5000, 20.00%
## -------------------------------------------------
## Sampled: 1500 of 5000, 30.00%
## -------------------------------------------------
## Sampled: 2000 of 5000, 40.00%
## -------------------------------------------------
## Sampled: 2500 of 5000, 50.00%
## -------------------------------------------------
## Sampled: 3000 of 5000, 60.00%
## -------------------------------------------------
## Sampled: 3500 of 5000, 70.00%
## -------------------------------------------------
## Sampled: 4000 of 5000, 80.00%
## -------------------------------------------------
## Sampled: 4500 of 5000, 90.00%
## -------------------------------------------------
## Sampled: 5000 of 5000, 100.00%
## ----------------------------------------
## Chain 2
## ----------------------------------------
## Sampling ...
## Sampled: 500 of 5000, 10.00%
## -------------------------------------------------
## Sampled: 1000 of 5000, 20.00%
## -------------------------------------------------
## Sampled: 1500 of 5000, 30.00%
## -------------------------------------------------
## Sampled: 2000 of 5000, 40.00%
## -------------------------------------------------
## Sampled: 2500 of 5000, 50.00%
## -------------------------------------------------
## Sampled: 3000 of 5000, 60.00%
## -------------------------------------------------
## Sampled: 3500 of 5000, 70.00%
## -------------------------------------------------
## Sampled: 4000 of 5000, 80.00%
## -------------------------------------------------
## Sampled: 4500 of 5000, 90.00%
## -------------------------------------------------
## Sampled: 5000 of 5000, 100.00%
## ----------------------------------------
## Chain 3
## ----------------------------------------
## Sampling ...
## Sampled: 500 of 5000, 10.00%
## -------------------------------------------------
## Sampled: 1000 of 5000, 20.00%
## -------------------------------------------------
## Sampled: 1500 of 5000, 30.00%
## -------------------------------------------------
## Sampled: 2000 of 5000, 40.00%
## -------------------------------------------------
## Sampled: 2500 of 5000, 50.00%
## -------------------------------------------------
## Sampled: 3000 of 5000, 60.00%
## -------------------------------------------------
## Sampled: 3500 of 5000, 70.00%
## -------------------------------------------------
## Sampled: 4000 of 5000, 80.00%
## -------------------------------------------------
## Sampled: 4500 of 5000, 90.00%
## -------------------------------------------------
## Sampled: 5000 of 5000, 100.00%
## ----------------------------------------
## Chain 4
## ----------------------------------------
## Sampling ...
## Sampled: 500 of 5000, 10.00%
## -------------------------------------------------
## Sampled: 1000 of 5000, 20.00%
## -------------------------------------------------
## Sampled: 1500 of 5000, 30.00%
## -------------------------------------------------
## Sampled: 2000 of 5000, 40.00%
## -------------------------------------------------
## Sampled: 2500 of 5000, 50.00%
## -------------------------------------------------
## Sampled: 3000 of 5000, 60.00%
## -------------------------------------------------
## Sampled: 3500 of 5000, 70.00%
## -------------------------------------------------
## Sampled: 4000 of 5000, 80.00%
## -------------------------------------------------
## Sampled: 4500 of 5000, 90.00%
## -------------------------------------------------
## Sampled: 5000 of 5000, 100.00%
summary(ms_cover_canopy)
##
## Call:
## msPGOcc(occ.formula = occ.canopy, det.formula = det.cover, data = data_list,
## n.samples = 5000, n.report = 500, n.burn = 3000, n.thin = 2,
## n.chains = 4)
##
## Samples per Chain: 5000
## Burn-in: 3000
## Thinning Rate: 2
## Number of Chains: 4
## Total Posterior Samples: 4000
## Run Time (min): 0.7468
##
## ----------------------------------------
## Community Level
## ----------------------------------------
## Occurrence Means (logit scale):
## Mean SD 2.5% 50% 97.5% Rhat ESS
## (Intercept) -0.4402 0.4803 -1.3812 -0.4478 0.5406 1.0158 632
## Tree_Density -0.8031 0.4688 -1.8961 -0.7610 -0.0162 1.0212 1022
## Avg_Canopy_Cover 1.1628 0.4768 0.2759 1.1294 2.1972 1.0117 942
##
## Occurrence Variances (logit scale):
## Mean SD 2.5% 50% 97.5% Rhat ESS
## (Intercept) 1.0870 1.2713 0.0921 0.7339 4.2096 1.0098 1091
## Tree_Density 1.0561 1.8964 0.0505 0.5062 5.5781 1.0407 880
## Avg_Canopy_Cover 1.2969 1.5569 0.1078 0.8296 5.5019 1.0096 775
##
## Occurrence Random Effect Variances (logit scale):
## Mean SD 2.5% 50% 97.5% Rhat ESS
## Auth 0.6862 0.7526 0.0495 0.4473 2.6004 1.1058 266
##
## Detection Means (logit scale):
## Mean SD 2.5% 50% 97.5% Rhat ESS
## (Intercept) -2.7481 0.3126 -3.3706 -2.7559 -2.0822 1.0086 2194
## shrub_cover 0.3049 0.3287 -0.3419 0.3006 0.9656 1.0056 2463
## veg_height 0.1023 0.1954 -0.2859 0.1024 0.5113 1.0035 2372
##
## Detection Variances (logit scale):
## Mean SD 2.5% 50% 97.5% Rhat ESS
## (Intercept) 0.7101 0.6505 0.1715 0.5436 2.2559 1.0174 1393
## shrub_cover 0.7473 0.7168 0.1510 0.5540 2.4969 1.0226 1609
## veg_height 0.2637 0.2425 0.0570 0.1962 0.8752 1.0039 2060
##
## ----------------------------------------
## Species Level
## ----------------------------------------
## Occurrence (logit scale):
## Mean SD 2.5% 50% 97.5%
## (Intercept)-Canis_latrans 0.0604 0.5826 -1.0576 0.0499 1.2397
## (Intercept)-Procyon_lotor 0.3505 0.6551 -0.9297 0.3439 1.5935
## (Intercept)-Dasypus_novemcinctus -0.8074 0.5649 -1.9916 -0.7829 0.2434
## (Intercept)-Lynx_rufus 0.1009 0.8967 -1.3265 0.0023 2.2629
## (Intercept)-Didelphis_virginiana -1.2360 0.6734 -2.6326 -1.1881 -0.0164
## (Intercept)-Sylvilagus_floridanus -0.6056 0.6178 -1.8549 -0.5987 0.5913
## (Intercept)-Meleagris_gallopavo -0.2572 0.7551 -1.6418 -0.3145 1.4217
## (Intercept)-Sciurus_carolinensis -1.2947 0.7119 -2.8190 -1.2416 0.0016
## Tree_Density-Canis_latrans -1.0062 0.6276 -2.4590 -0.9264 0.0003
## Tree_Density-Procyon_lotor -0.4890 0.4313 -1.3682 -0.4771 0.3314
## Tree_Density-Dasypus_novemcinctus -1.4540 0.9550 -3.8034 -1.2524 -0.1570
## Tree_Density-Lynx_rufus 0.2172 0.7776 -0.9550 0.0868 2.1399
## Tree_Density-Didelphis_virginiana -0.9682 0.7571 -2.8248 -0.8590 0.2065
## Tree_Density-Sylvilagus_floridanus -1.1186 0.8235 -3.0696 -0.9941 0.1548
## Tree_Density-Meleagris_gallopavo -1.0406 0.8111 -2.9686 -0.9320 0.2241
## Tree_Density-Sciurus_carolinensis -0.8656 0.7659 -2.7125 -0.7815 0.4093
## Avg_Canopy_Cover-Canis_latrans -0.0908 0.4833 -1.0671 -0.0829 0.8525
## Avg_Canopy_Cover-Procyon_lotor 1.0629 0.5056 0.1645 1.0351 2.1148
## Avg_Canopy_Cover-Dasypus_novemcinctus 1.1448 0.5005 0.2612 1.1077 2.2620
## Avg_Canopy_Cover-Lynx_rufus 0.7616 0.7507 -0.6063 0.7200 2.4372
## Avg_Canopy_Cover-Didelphis_virginiana 1.6151 0.7408 0.5016 1.5074 3.3501
## Avg_Canopy_Cover-Sylvilagus_floridanus 2.2302 1.0509 0.7094 2.0164 4.7916
## Avg_Canopy_Cover-Meleagris_gallopavo 1.6079 0.8234 0.2768 1.4969 3.5053
## Avg_Canopy_Cover-Sciurus_carolinensis 1.5242 0.6865 0.4635 1.4197 3.1158
## Rhat ESS
## (Intercept)-Canis_latrans 1.0106 776
## (Intercept)-Procyon_lotor 1.0191 556
## (Intercept)-Dasypus_novemcinctus 1.0004 1182
## (Intercept)-Lynx_rufus 1.0253 358
## (Intercept)-Didelphis_virginiana 1.0108 983
## (Intercept)-Sylvilagus_floridanus 1.0053 1471
## (Intercept)-Meleagris_gallopavo 1.0277 482
## (Intercept)-Sciurus_carolinensis 1.0066 967
## Tree_Density-Canis_latrans 1.0173 1452
## Tree_Density-Procyon_lotor 1.0029 2155
## Tree_Density-Dasypus_novemcinctus 1.0378 660
## Tree_Density-Lynx_rufus 1.0291 671
## Tree_Density-Didelphis_virginiana 1.0404 720
## Tree_Density-Sylvilagus_floridanus 1.0174 722
## Tree_Density-Meleagris_gallopavo 1.0084 959
## Tree_Density-Sciurus_carolinensis 1.0121 1102
## Avg_Canopy_Cover-Canis_latrans 1.0032 1185
## Avg_Canopy_Cover-Procyon_lotor 1.0013 2043
## Avg_Canopy_Cover-Dasypus_novemcinctus 1.0111 2357
## Avg_Canopy_Cover-Lynx_rufus 1.0041 747
## Avg_Canopy_Cover-Didelphis_virginiana 1.0249 725
## Avg_Canopy_Cover-Sylvilagus_floridanus 1.0107 495
## Avg_Canopy_Cover-Meleagris_gallopavo 1.0142 624
## Avg_Canopy_Cover-Sciurus_carolinensis 1.0199 732
##
## Detection (logit scale):
## Mean SD 2.5% 50% 97.5% Rhat
## (Intercept)-Canis_latrans -2.7358 0.1865 -3.1130 -2.7300 -2.3844 1.0006
## (Intercept)-Procyon_lotor -2.3020 0.1436 -2.5962 -2.2991 -2.0364 1.0133
## (Intercept)-Dasypus_novemcinctus -1.7833 0.1645 -2.1079 -1.7787 -1.4647 1.0032
## (Intercept)-Lynx_rufus -3.6561 0.3458 -4.3486 -3.6515 -2.9804 1.0073
## (Intercept)-Didelphis_virginiana -2.6535 0.2815 -3.2242 -2.6504 -2.1268 1.0095
## (Intercept)-Sylvilagus_floridanus -3.0940 0.2536 -3.6127 -3.0899 -2.6114 1.0025
## (Intercept)-Meleagris_gallopavo -3.7513 0.4293 -4.5827 -3.7409 -2.9331 1.0108
## (Intercept)-Sciurus_carolinensis -2.7397 0.3134 -3.3782 -2.7224 -2.1452 1.0418
## shrub_cover-Canis_latrans -0.2952 0.2194 -0.7328 -0.3009 0.1496 1.0070
## shrub_cover-Procyon_lotor 0.2617 0.1638 -0.0745 0.2677 0.5723 1.0019
## shrub_cover-Dasypus_novemcinctus 0.9135 0.2997 0.3141 0.9125 1.4920 1.0109
## shrub_cover-Lynx_rufus -0.2774 0.3463 -0.9675 -0.2740 0.4072 1.0014
## shrub_cover-Didelphis_virginiana 1.0453 0.3716 0.3447 1.0287 1.8084 1.0137
## shrub_cover-Sylvilagus_floridanus 0.4397 0.3770 -0.3139 0.4492 1.1914 1.0038
## shrub_cover-Meleagris_gallopavo -0.5905 0.3950 -1.3622 -0.5938 0.1650 1.0083
## shrub_cover-Sciurus_carolinensis 0.9629 0.4136 0.1377 0.9724 1.7595 1.0251
## veg_height-Canis_latrans -0.5733 0.1850 -0.9475 -0.5679 -0.2296 1.0036
## veg_height-Procyon_lotor 0.3520 0.1240 0.1114 0.3498 0.5917 1.0031
## veg_height-Dasypus_novemcinctus 0.2716 0.1385 0.0090 0.2717 0.5435 1.0015
## veg_height-Lynx_rufus 0.0826 0.2375 -0.3877 0.0862 0.5434 1.0056
## veg_height-Didelphis_virginiana 0.5151 0.2414 0.0723 0.5094 1.0135 1.0028
## veg_height-Sylvilagus_floridanus 0.1820 0.2309 -0.2529 0.1833 0.6468 1.0186
## veg_height-Meleagris_gallopavo -0.1533 0.3558 -0.8924 -0.1463 0.5211 1.0083
## veg_height-Sciurus_carolinensis 0.1458 0.2218 -0.2942 0.1452 0.6031 1.0089
## ESS
## (Intercept)-Canis_latrans 1027
## (Intercept)-Procyon_lotor 1585
## (Intercept)-Dasypus_novemcinctus 1955
## (Intercept)-Lynx_rufus 351
## (Intercept)-Didelphis_virginiana 982
## (Intercept)-Sylvilagus_floridanus 912
## (Intercept)-Meleagris_gallopavo 349
## (Intercept)-Sciurus_carolinensis 687
## shrub_cover-Canis_latrans 1120
## shrub_cover-Procyon_lotor 2038
## shrub_cover-Dasypus_novemcinctus 1640
## shrub_cover-Lynx_rufus 546
## shrub_cover-Didelphis_virginiana 891
## shrub_cover-Sylvilagus_floridanus 837
## shrub_cover-Meleagris_gallopavo 499
## shrub_cover-Sciurus_carolinensis 815
## veg_height-Canis_latrans 804
## veg_height-Procyon_lotor 2174
## veg_height-Dasypus_novemcinctus 2645
## veg_height-Lynx_rufus 1002
## veg_height-Didelphis_virginiana 1395
## veg_height-Sylvilagus_floridanus 1473
## veg_height-Meleagris_gallopavo 862
## veg_height-Sciurus_carolinensis 1024
# Includes quadratic week covariate of detection and quadratic cogon for occupancy
ms_weekQ_cogonQ<- msPGOcc(
occ.formula = occ.cogon.quad,
det.formula = det.week.quad,
data = data_list,
n.samples = 5000,
n.thin = 2,
n.burn = 3000,
n.chains = 4,
n.report = 500,
)
## ----------------------------------------
## Preparing to run the model
## ----------------------------------------
## No prior specified for beta.comm.normal.
## Setting prior mean to 0 and prior variance to 2.72
## No prior specified for alpha.comm.normal.
## Setting prior mean to 0 and prior variance to 2.72
## No prior specified for tau.sq.beta.ig.
## Setting prior shape to 0.1 and prior scale to 0.1
## No prior specified for tau.sq.alpha.ig.
## Setting prior shape to 0.1 and prior scale to 0.1
## No prior specified for sigma.sq.psi.ig.
## Setting prior shape to 0.1 and prior scale to 0.1
## z is not specified in initial values.
## Setting initial values based on observed data
## beta.comm is not specified in initial values.
## Setting initial values to random values from the prior distribution
## alpha.comm is not specified in initial values.
## Setting initial values to random values from the prior distribution
## tau.sq.beta is not specified in initial values.
## Setting initial values to random values between 0.5 and 10
## tau.sq.alpha is not specified in initial values.
## Setting to initial values to random values between 0.5 and 10
## beta is not specified in initial values.
## Setting initial values to random values from the community-level normal distribution
## alpha is not specified in initial values.
## Setting initial values to random values from the community-level normal distribution
## sigma.sq.psi is not specified in initial values.
## Setting initial values to random values between 0.5 and 10
## ----------------------------------------
## Model description
## ----------------------------------------
## Multi-species Occupancy Model with Polya-Gamma latent
## variable fit with 32 sites and 8 species.
##
## Samples per Chain: 5000
## Burn-in: 3000
## Thinning Rate: 2
## Number of Chains: 4
## Total Posterior Samples: 4000
##
## Source compiled with OpenMP support and model fit using 1 thread(s).
##
## ----------------------------------------
## Chain 1
## ----------------------------------------
## Sampling ...
## Sampled: 500 of 5000, 10.00%
## -------------------------------------------------
## Sampled: 1000 of 5000, 20.00%
## -------------------------------------------------
## Sampled: 1500 of 5000, 30.00%
## -------------------------------------------------
## Sampled: 2000 of 5000, 40.00%
## -------------------------------------------------
## Sampled: 2500 of 5000, 50.00%
## -------------------------------------------------
## Sampled: 3000 of 5000, 60.00%
## -------------------------------------------------
## Sampled: 3500 of 5000, 70.00%
## -------------------------------------------------
## Sampled: 4000 of 5000, 80.00%
## -------------------------------------------------
## Sampled: 4500 of 5000, 90.00%
## -------------------------------------------------
## Sampled: 5000 of 5000, 100.00%
## ----------------------------------------
## Chain 2
## ----------------------------------------
## Sampling ...
## Sampled: 500 of 5000, 10.00%
## -------------------------------------------------
## Sampled: 1000 of 5000, 20.00%
## -------------------------------------------------
## Sampled: 1500 of 5000, 30.00%
## -------------------------------------------------
## Sampled: 2000 of 5000, 40.00%
## -------------------------------------------------
## Sampled: 2500 of 5000, 50.00%
## -------------------------------------------------
## Sampled: 3000 of 5000, 60.00%
## -------------------------------------------------
## Sampled: 3500 of 5000, 70.00%
## -------------------------------------------------
## Sampled: 4000 of 5000, 80.00%
## -------------------------------------------------
## Sampled: 4500 of 5000, 90.00%
## -------------------------------------------------
## Sampled: 5000 of 5000, 100.00%
## ----------------------------------------
## Chain 3
## ----------------------------------------
## Sampling ...
## Sampled: 500 of 5000, 10.00%
## -------------------------------------------------
## Sampled: 1000 of 5000, 20.00%
## -------------------------------------------------
## Sampled: 1500 of 5000, 30.00%
## -------------------------------------------------
## Sampled: 2000 of 5000, 40.00%
## -------------------------------------------------
## Sampled: 2500 of 5000, 50.00%
## -------------------------------------------------
## Sampled: 3000 of 5000, 60.00%
## -------------------------------------------------
## Sampled: 3500 of 5000, 70.00%
## -------------------------------------------------
## Sampled: 4000 of 5000, 80.00%
## -------------------------------------------------
## Sampled: 4500 of 5000, 90.00%
## -------------------------------------------------
## Sampled: 5000 of 5000, 100.00%
## ----------------------------------------
## Chain 4
## ----------------------------------------
## Sampling ...
## Sampled: 500 of 5000, 10.00%
## -------------------------------------------------
## Sampled: 1000 of 5000, 20.00%
## -------------------------------------------------
## Sampled: 1500 of 5000, 30.00%
## -------------------------------------------------
## Sampled: 2000 of 5000, 40.00%
## -------------------------------------------------
## Sampled: 2500 of 5000, 50.00%
## -------------------------------------------------
## Sampled: 3000 of 5000, 60.00%
## -------------------------------------------------
## Sampled: 3500 of 5000, 70.00%
## -------------------------------------------------
## Sampled: 4000 of 5000, 80.00%
## -------------------------------------------------
## Sampled: 4500 of 5000, 90.00%
## -------------------------------------------------
## Sampled: 5000 of 5000, 100.00%
summary(ms_weekQ_cogonQ)
##
## Call:
## msPGOcc(occ.formula = occ.cogon.quad, det.formula = det.week.quad,
## data = data_list, n.samples = 5000, n.report = 500, n.burn = 3000,
## n.thin = 2, n.chains = 4)
##
## Samples per Chain: 5000
## Burn-in: 3000
## Thinning Rate: 2
## Number of Chains: 4
## Total Posterior Samples: 4000
## Run Time (min): 0.8945
##
## ----------------------------------------
## Community Level
## ----------------------------------------
## Occurrence Means (logit scale):
## Mean SD 2.5% 50% 97.5% Rhat ESS
## (Intercept) -1.1628 0.4147 -1.9754 -1.1546 -0.3605 1.0035 853
## Avg_Cogongrass_Cover -0.5606 0.3789 -1.3281 -0.5505 0.1588 1.0282 716
## I(Avg_Cogongrass_Cover^2) 0.7773 0.3855 0.1078 0.7479 1.6254 1.0067 658
##
## Occurrence Variances (logit scale):
## Mean SD 2.5% 50% 97.5% Rhat ESS
## (Intercept) 0.6152 0.7278 0.0549 0.3794 2.6263 1.0234 1579
## Avg_Cogongrass_Cover 0.3822 0.4790 0.0394 0.2299 1.6098 1.0017 1551
## I(Avg_Cogongrass_Cover^2) 0.6095 1.1180 0.0430 0.2857 3.0169 1.0864 540
##
## Occurrence Random Effect Variances (logit scale):
## Mean SD 2.5% 50% 97.5% Rhat ESS
## Auth 0.5252 0.555 0.0539 0.3489 1.936 1.0135 359
##
## Detection Means (logit scale):
## Mean SD 2.5% 50% 97.5% Rhat ESS
## (Intercept) -2.4301 0.2850 -2.9560 -2.4363 -1.8430 1.0011 2375
## week 0.1769 0.2031 -0.2283 0.1780 0.5971 1.0051 1635
## I(week^2) -0.2222 0.1205 -0.4728 -0.2173 0.0015 1.0321 1288
##
## Detection Variances (logit scale):
## Mean SD 2.5% 50% 97.5% Rhat ESS
## (Intercept) 0.5692 0.4983 0.1383 0.4400 1.8020 1.0037 2799
## week 0.1972 0.2103 0.0331 0.1342 0.7443 1.0146 1670
## I(week^2) 0.0811 0.1008 0.0189 0.0569 0.2743 1.1456 963
##
## ----------------------------------------
## Species Level
## ----------------------------------------
## Occurrence (logit scale):
## Mean SD 2.5% 50%
## (Intercept)-Canis_latrans -0.8003 0.5684 -1.8967 -0.7963
## (Intercept)-Procyon_lotor -0.5926 0.5968 -1.7338 -0.6092
## (Intercept)-Dasypus_novemcinctus -1.2684 0.5107 -2.3313 -1.2620
## (Intercept)-Lynx_rufus -1.2547 0.5949 -2.4783 -1.2541
## (Intercept)-Didelphis_virginiana -1.5966 0.5655 -2.8253 -1.5504
## (Intercept)-Sylvilagus_floridanus -1.1439 0.5546 -2.2586 -1.1486
## (Intercept)-Meleagris_gallopavo -0.9989 0.5656 -2.0981 -1.0239
## (Intercept)-Sciurus_carolinensis -1.8347 0.6467 -3.2171 -1.7831
## Avg_Cogongrass_Cover-Canis_latrans -0.4037 0.4944 -1.3393 -0.4174
## Avg_Cogongrass_Cover-Procyon_lotor -0.5543 0.5017 -1.5391 -0.5506
## Avg_Cogongrass_Cover-Dasypus_novemcinctus -0.4279 0.4704 -1.3414 -0.4355
## Avg_Cogongrass_Cover-Lynx_rufus -0.4877 0.5397 -1.5602 -0.4955
## Avg_Cogongrass_Cover-Didelphis_virginiana -0.2871 0.5132 -1.2299 -0.3089
## Avg_Cogongrass_Cover-Sylvilagus_floridanus -1.0067 0.5796 -2.2768 -0.9685
## Avg_Cogongrass_Cover-Meleagris_gallopavo -0.8558 0.5662 -2.0882 -0.8240
## Avg_Cogongrass_Cover-Sciurus_carolinensis -0.5860 0.5134 -1.6100 -0.5659
## I(Avg_Cogongrass_Cover^2)-Canis_latrans 1.3272 0.8947 0.2386 1.1086
## I(Avg_Cogongrass_Cover^2)-Procyon_lotor 1.2101 0.7605 0.2464 1.0303
## I(Avg_Cogongrass_Cover^2)-Dasypus_novemcinctus 0.6341 0.3370 -0.0046 0.6272
## I(Avg_Cogongrass_Cover^2)-Lynx_rufus 1.1349 0.5345 0.3052 1.0665
## I(Avg_Cogongrass_Cover^2)-Didelphis_virginiana 0.4280 0.3956 -0.3339 0.4234
## I(Avg_Cogongrass_Cover^2)-Sylvilagus_floridanus 0.6888 0.4645 -0.1099 0.6398
## I(Avg_Cogongrass_Cover^2)-Meleagris_gallopavo 0.1842 0.5808 -1.0821 0.2120
## I(Avg_Cogongrass_Cover^2)-Sciurus_carolinensis 0.8083 0.3773 0.1350 0.7873
## 97.5% Rhat ESS
## (Intercept)-Canis_latrans 0.3074 1.0068 995
## (Intercept)-Procyon_lotor 0.6154 1.0250 791
## (Intercept)-Dasypus_novemcinctus -0.2635 1.0071 1573
## (Intercept)-Lynx_rufus -0.0450 1.0116 891
## (Intercept)-Didelphis_virginiana -0.6156 1.0109 1268
## (Intercept)-Sylvilagus_floridanus -0.0482 1.0050 937
## (Intercept)-Meleagris_gallopavo 0.1728 1.0022 1027
## (Intercept)-Sciurus_carolinensis -0.7441 1.0286 944
## Avg_Cogongrass_Cover-Canis_latrans 0.6146 1.0117 1293
## Avg_Cogongrass_Cover-Procyon_lotor 0.4269 1.0107 1318
## Avg_Cogongrass_Cover-Dasypus_novemcinctus 0.5111 1.0144 1499
## Avg_Cogongrass_Cover-Lynx_rufus 0.5777 1.0099 1262
## Avg_Cogongrass_Cover-Didelphis_virginiana 0.7605 1.0097 1395
## Avg_Cogongrass_Cover-Sylvilagus_floridanus 0.0131 1.0153 983
## Avg_Cogongrass_Cover-Meleagris_gallopavo 0.1611 1.0199 1041
## Avg_Cogongrass_Cover-Sciurus_carolinensis 0.3836 1.0254 1106
## I(Avg_Cogongrass_Cover^2)-Canis_latrans 3.6476 1.0178 374
## I(Avg_Cogongrass_Cover^2)-Procyon_lotor 3.3141 1.0143 388
## I(Avg_Cogongrass_Cover^2)-Dasypus_novemcinctus 1.3380 1.0163 1232
## I(Avg_Cogongrass_Cover^2)-Lynx_rufus 2.4220 1.0102 614
## I(Avg_Cogongrass_Cover^2)-Didelphis_virginiana 1.2477 1.0067 1149
## I(Avg_Cogongrass_Cover^2)-Sylvilagus_floridanus 1.7426 1.0124 880
## I(Avg_Cogongrass_Cover^2)-Meleagris_gallopavo 1.2946 1.0101 648
## I(Avg_Cogongrass_Cover^2)-Sciurus_carolinensis 1.6208 1.0219 1000
##
## Detection (logit scale):
## Mean SD 2.5% 50% 97.5% Rhat
## (Intercept)-Canis_latrans -2.4676 0.1844 -2.8442 -2.4595 -2.1297 1.0009
## (Intercept)-Procyon_lotor -2.1806 0.1487 -2.4746 -2.1809 -1.9027 1.0021
## (Intercept)-Dasypus_novemcinctus -1.4966 0.1623 -1.8191 -1.4924 -1.1849 1.0010
## (Intercept)-Lynx_rufus -3.1497 0.2909 -3.7391 -3.1425 -2.6078 1.0021
## (Intercept)-Didelphis_virginiana -2.1827 0.2704 -2.7284 -2.1804 -1.6718 1.0045
## (Intercept)-Sylvilagus_floridanus -3.0009 0.2927 -3.6131 -2.9849 -2.4731 1.0039
## (Intercept)-Meleagris_gallopavo -3.1057 0.3320 -3.8043 -3.0915 -2.4979 1.0222
## (Intercept)-Sciurus_carolinensis -2.3509 0.2850 -2.9440 -2.3381 -1.8251 1.0063
## week-Canis_latrans 0.4385 0.2394 -0.0004 0.4264 0.9357 1.0157
## week-Procyon_lotor 0.1612 0.1934 -0.2206 0.1595 0.5564 1.0030
## week-Dasypus_novemcinctus 0.0597 0.2078 -0.3517 0.0612 0.4645 1.0033
## week-Lynx_rufus 0.2566 0.2946 -0.3144 0.2531 0.8788 1.0049
## week-Didelphis_virginiana 0.0273 0.3120 -0.6486 0.0402 0.6116 1.0027
## week-Sylvilagus_floridanus 0.0491 0.2882 -0.5538 0.0589 0.5930 1.0089
## week-Meleagris_gallopavo -0.1048 0.3314 -0.8184 -0.0832 0.5059 1.0049
## week-Sciurus_carolinensis 0.5254 0.3363 -0.0728 0.5036 1.2316 1.0063
## I(week^2)-Canis_latrans -0.1924 0.1028 -0.4002 -0.1881 0.0000 1.0083
## I(week^2)-Procyon_lotor -0.1147 0.0868 -0.2905 -0.1122 0.0514 1.0013
## I(week^2)-Dasypus_novemcinctus -0.1521 0.1022 -0.3618 -0.1497 0.0410 1.0000
## I(week^2)-Lynx_rufus -0.2099 0.1460 -0.5156 -0.2049 0.0602 1.0223
## I(week^2)-Didelphis_virginiana -0.3548 0.2108 -0.8162 -0.3294 -0.0119 1.0414
## I(week^2)-Sylvilagus_floridanus -0.1675 0.1488 -0.4806 -0.1638 0.1165 1.0209
## I(week^2)-Meleagris_gallopavo -0.3776 0.2366 -0.9229 -0.3514 0.0123 1.0978
## I(week^2)-Sciurus_carolinensis -0.1917 0.1402 -0.4765 -0.1855 0.0734 1.0050
## ESS
## (Intercept)-Canis_latrans 1566
## (Intercept)-Procyon_lotor 2093
## (Intercept)-Dasypus_novemcinctus 2946
## (Intercept)-Lynx_rufus 836
## (Intercept)-Didelphis_virginiana 1731
## (Intercept)-Sylvilagus_floridanus 756
## (Intercept)-Meleagris_gallopavo 681
## (Intercept)-Sciurus_carolinensis 1571
## week-Canis_latrans 1638
## week-Procyon_lotor 2136
## week-Dasypus_novemcinctus 2619
## week-Lynx_rufus 1477
## week-Didelphis_virginiana 1696
## week-Sylvilagus_floridanus 1727
## week-Meleagris_gallopavo 1118
## week-Sciurus_carolinensis 1665
## I(week^2)-Canis_latrans 1675
## I(week^2)-Procyon_lotor 2019
## I(week^2)-Dasypus_novemcinctus 2133
## I(week^2)-Lynx_rufus 1116
## I(week^2)-Didelphis_virginiana 618
## I(week^2)-Sylvilagus_floridanus 1079
## I(week^2)-Meleagris_gallopavo 428
## I(week^2)-Sciurus_carolinensis 1837
# Includes quadratic week and full covariates of detection and all covariates and coverage for occupancy
ms_fullQ_cover<- msPGOcc(
occ.formula = occ.cover,
det.formula = det.full.quad,
data = data_list,
n.samples = 5000,
n.thin = 2,
n.burn = 3000,
n.chains = 4,
n.report = 500,
)
## ----------------------------------------
## Preparing to run the model
## ----------------------------------------
## Warning in (function (..., row.names = NULL, check.rows = FALSE, check.names =
## TRUE, : row names were found from a short variable and have been discarded
## No prior specified for beta.comm.normal.
## Setting prior mean to 0 and prior variance to 2.72
## No prior specified for alpha.comm.normal.
## Setting prior mean to 0 and prior variance to 2.72
## No prior specified for tau.sq.beta.ig.
## Setting prior shape to 0.1 and prior scale to 0.1
## No prior specified for tau.sq.alpha.ig.
## Setting prior shape to 0.1 and prior scale to 0.1
## No prior specified for sigma.sq.psi.ig.
## Setting prior shape to 0.1 and prior scale to 0.1
## z is not specified in initial values.
## Setting initial values based on observed data
## beta.comm is not specified in initial values.
## Setting initial values to random values from the prior distribution
## alpha.comm is not specified in initial values.
## Setting initial values to random values from the prior distribution
## tau.sq.beta is not specified in initial values.
## Setting initial values to random values between 0.5 and 10
## tau.sq.alpha is not specified in initial values.
## Setting to initial values to random values between 0.5 and 10
## beta is not specified in initial values.
## Setting initial values to random values from the community-level normal distribution
## alpha is not specified in initial values.
## Setting initial values to random values from the community-level normal distribution
## sigma.sq.psi is not specified in initial values.
## Setting initial values to random values between 0.5 and 10
## ----------------------------------------
## Model description
## ----------------------------------------
## Multi-species Occupancy Model with Polya-Gamma latent
## variable fit with 32 sites and 8 species.
##
## Samples per Chain: 5000
## Burn-in: 3000
## Thinning Rate: 2
## Number of Chains: 4
## Total Posterior Samples: 4000
##
## Source compiled with OpenMP support and model fit using 1 thread(s).
##
## ----------------------------------------
## Chain 1
## ----------------------------------------
## Sampling ...
## Sampled: 500 of 5000, 10.00%
## -------------------------------------------------
## Sampled: 1000 of 5000, 20.00%
## -------------------------------------------------
## Sampled: 1500 of 5000, 30.00%
## -------------------------------------------------
## Sampled: 2000 of 5000, 40.00%
## -------------------------------------------------
## Sampled: 2500 of 5000, 50.00%
## -------------------------------------------------
## Sampled: 3000 of 5000, 60.00%
## -------------------------------------------------
## Sampled: 3500 of 5000, 70.00%
## -------------------------------------------------
## Sampled: 4000 of 5000, 80.00%
## -------------------------------------------------
## Sampled: 4500 of 5000, 90.00%
## -------------------------------------------------
## Sampled: 5000 of 5000, 100.00%
## ----------------------------------------
## Chain 2
## ----------------------------------------
## Sampling ...
## Sampled: 500 of 5000, 10.00%
## -------------------------------------------------
## Sampled: 1000 of 5000, 20.00%
## -------------------------------------------------
## Sampled: 1500 of 5000, 30.00%
## -------------------------------------------------
## Sampled: 2000 of 5000, 40.00%
## -------------------------------------------------
## Sampled: 2500 of 5000, 50.00%
## -------------------------------------------------
## Sampled: 3000 of 5000, 60.00%
## -------------------------------------------------
## Sampled: 3500 of 5000, 70.00%
## -------------------------------------------------
## Sampled: 4000 of 5000, 80.00%
## -------------------------------------------------
## Sampled: 4500 of 5000, 90.00%
## -------------------------------------------------
## Sampled: 5000 of 5000, 100.00%
## ----------------------------------------
## Chain 3
## ----------------------------------------
## Sampling ...
## Sampled: 500 of 5000, 10.00%
## -------------------------------------------------
## Sampled: 1000 of 5000, 20.00%
## -------------------------------------------------
## Sampled: 1500 of 5000, 30.00%
## -------------------------------------------------
## Sampled: 2000 of 5000, 40.00%
## -------------------------------------------------
## Sampled: 2500 of 5000, 50.00%
## -------------------------------------------------
## Sampled: 3000 of 5000, 60.00%
## -------------------------------------------------
## Sampled: 3500 of 5000, 70.00%
## -------------------------------------------------
## Sampled: 4000 of 5000, 80.00%
## -------------------------------------------------
## Sampled: 4500 of 5000, 90.00%
## -------------------------------------------------
## Sampled: 5000 of 5000, 100.00%
## ----------------------------------------
## Chain 4
## ----------------------------------------
## Sampling ...
## Sampled: 500 of 5000, 10.00%
## -------------------------------------------------
## Sampled: 1000 of 5000, 20.00%
## -------------------------------------------------
## Sampled: 1500 of 5000, 30.00%
## -------------------------------------------------
## Sampled: 2000 of 5000, 40.00%
## -------------------------------------------------
## Sampled: 2500 of 5000, 50.00%
## -------------------------------------------------
## Sampled: 3000 of 5000, 60.00%
## -------------------------------------------------
## Sampled: 3500 of 5000, 70.00%
## -------------------------------------------------
## Sampled: 4000 of 5000, 80.00%
## -------------------------------------------------
## Sampled: 4500 of 5000, 90.00%
## -------------------------------------------------
## Sampled: 5000 of 5000, 100.00%
summary(ms_fullQ_cover)
##
## Call:
## msPGOcc(occ.formula = occ.cover, det.formula = det.full.quad,
## data = data_list, n.samples = 5000, n.report = 500, n.burn = 3000,
## n.thin = 2, n.chains = 4)
##
## Samples per Chain: 5000
## Burn-in: 3000
## Thinning Rate: 2
## Number of Chains: 4
## Total Posterior Samples: 4000
## Run Time (min): 1.1348
##
## ----------------------------------------
## Community Level
## ----------------------------------------
## Occurrence Means (logit scale):
## Mean SD 2.5% 50% 97.5% Rhat ESS
## (Intercept) -0.1385 0.4555 -0.9886 -0.1502 0.8214 1.0048 290
## Avg_Cogongrass_Cover -0.0213 0.4090 -0.8492 -0.0143 0.7528 1.0390 736
## total_shrub_cover -0.9684 0.4850 -1.9733 -0.9399 -0.0965 1.0207 559
## avg_veg_height 0.1594 0.4170 -0.6642 0.1489 1.0183 1.0119 420
##
## Occurrence Variances (logit scale):
## Mean SD 2.5% 50% 97.5% Rhat ESS
## (Intercept) 0.5627 0.7630 0.0448 0.3343 2.2866 1.0116 1032
## Avg_Cogongrass_Cover 0.5214 0.7866 0.0438 0.2870 2.5393 1.0254 1126
## total_shrub_cover 1.0547 1.4945 0.0748 0.6397 4.5754 1.0758 919
## avg_veg_height 0.4325 1.2439 0.0374 0.2317 1.9040 1.2506 1456
##
## Occurrence Random Effect Variances (logit scale):
## Mean SD 2.5% 50% 97.5% Rhat ESS
## Auth 1.1824 1.1007 0.1203 0.8519 3.9313 1.0282 313
##
## Detection Means (logit scale):
## Mean SD 2.5% 50% 97.5% Rhat ESS
## (Intercept) -2.6450 0.2894 -3.2164 -2.6436 -2.0920 1.0144 1371
## shrub_cover 0.5552 0.3244 -0.0729 0.5505 1.2200 1.0021 2020
## veg_height 0.0898 0.2077 -0.3379 0.0987 0.4853 1.0190 1026
## week 0.1939 0.2078 -0.2064 0.1924 0.6048 1.0045 1545
## I(week^2) -0.2255 0.1248 -0.4872 -0.2207 0.0079 1.0097 1484
##
## Detection Variances (logit scale):
## Mean SD 2.5% 50% 97.5% Rhat ESS
## (Intercept) 0.5489 0.4739 0.1158 0.4185 1.7687 1.0178 1219
## shrub_cover 0.8186 0.7353 0.1440 0.6198 2.6857 1.0169 648
## veg_height 0.2697 0.2498 0.0616 0.1999 0.9059 1.0207 1751
## week 0.2043 0.2524 0.0346 0.1364 0.7763 1.0132 1584
## I(week^2) 0.0841 0.0964 0.0200 0.0603 0.2836 1.0592 1315
##
## ----------------------------------------
## Species Level
## ----------------------------------------
## Occurrence (logit scale):
## Mean SD 2.5% 50%
## (Intercept)-Canis_latrans 0.2124 0.6090 -0.9128 0.1807
## (Intercept)-Procyon_lotor 0.3566 0.6305 -0.8451 0.3305
## (Intercept)-Dasypus_novemcinctus -0.2487 0.5989 -1.3749 -0.2598
## (Intercept)-Lynx_rufus -0.1340 0.6565 -1.3343 -0.1535
## (Intercept)-Didelphis_virginiana -0.4777 0.6412 -1.7508 -0.4691
## (Intercept)-Sylvilagus_floridanus -0.0102 0.6587 -1.1822 -0.0501
## (Intercept)-Meleagris_gallopavo -0.3214 0.6882 -1.6761 -0.3148
## (Intercept)-Sciurus_carolinensis -0.4858 0.6680 -1.8892 -0.4646
## Avg_Cogongrass_Cover-Canis_latrans 0.3285 0.5351 -0.6815 0.2926
## Avg_Cogongrass_Cover-Procyon_lotor -0.1076 0.4906 -1.0993 -0.0895
## Avg_Cogongrass_Cover-Dasypus_novemcinctus 0.1308 0.4784 -0.7941 0.1232
## Avg_Cogongrass_Cover-Lynx_rufus 0.3584 0.5720 -0.6380 0.3106
## Avg_Cogongrass_Cover-Didelphis_virginiana 0.1222 0.5326 -0.9449 0.1160
## Avg_Cogongrass_Cover-Sylvilagus_floridanus -0.4680 0.6109 -1.8384 -0.4163
## Avg_Cogongrass_Cover-Meleagris_gallopavo -0.4856 0.6945 -2.1149 -0.4143
## Avg_Cogongrass_Cover-Sciurus_carolinensis -0.0069 0.5323 -1.1003 0.0094
## total_shrub_cover-Canis_latrans 0.1276 0.6431 -1.0347 0.0813
## total_shrub_cover-Procyon_lotor -1.3030 0.5964 -2.6617 -1.2295
## total_shrub_cover-Dasypus_novemcinctus -0.5987 0.6741 -2.2125 -0.5204
## total_shrub_cover-Lynx_rufus -1.3990 0.7932 -3.1305 -1.3060
## total_shrub_cover-Didelphis_virginiana -1.0100 0.6890 -2.5804 -0.9461
## total_shrub_cover-Sylvilagus_floridanus -1.3674 0.8695 -3.4233 -1.2516
## total_shrub_cover-Meleagris_gallopavo -1.5782 0.8145 -3.4419 -1.4933
## total_shrub_cover-Sciurus_carolinensis -1.0601 0.7722 -2.8288 -0.9842
## avg_veg_height-Canis_latrans 0.1482 0.5022 -0.8538 0.1276
## avg_veg_height-Procyon_lotor 0.1836 0.5009 -0.7729 0.1604
## avg_veg_height-Dasypus_novemcinctus 0.3964 0.5179 -0.5478 0.3768
## avg_veg_height-Lynx_rufus 0.0778 0.6198 -1.1864 0.0745
## avg_veg_height-Didelphis_virginiana 0.0252 0.5335 -1.0495 0.0302
## avg_veg_height-Sylvilagus_floridanus 0.0952 0.5695 -0.9656 0.0882
## avg_veg_height-Meleagris_gallopavo -0.1550 0.7462 -1.7770 -0.1080
## avg_veg_height-Sciurus_carolinensis 0.5413 0.5710 -0.4687 0.4932
## 97.5% Rhat ESS
## (Intercept)-Canis_latrans 1.4955 1.0028 629
## (Intercept)-Procyon_lotor 1.6881 1.0107 549
## (Intercept)-Dasypus_novemcinctus 0.9993 1.0041 390
## (Intercept)-Lynx_rufus 1.2485 1.0105 586
## (Intercept)-Didelphis_virginiana 0.7673 1.0108 425
## (Intercept)-Sylvilagus_floridanus 1.4311 1.0047 400
## (Intercept)-Meleagris_gallopavo 1.0925 1.0076 385
## (Intercept)-Sciurus_carolinensis 0.7590 1.0272 476
## Avg_Cogongrass_Cover-Canis_latrans 1.4603 1.0142 1061
## Avg_Cogongrass_Cover-Procyon_lotor 0.8022 1.0087 935
## Avg_Cogongrass_Cover-Dasypus_novemcinctus 1.1204 1.0048 1150
## Avg_Cogongrass_Cover-Lynx_rufus 1.6633 1.0184 1132
## Avg_Cogongrass_Cover-Didelphis_virginiana 1.2014 1.0136 1164
## Avg_Cogongrass_Cover-Sylvilagus_floridanus 0.5903 1.0129 884
## Avg_Cogongrass_Cover-Meleagris_gallopavo 0.6881 1.0128 733
## Avg_Cogongrass_Cover-Sciurus_carolinensis 0.9979 1.0125 883
## total_shrub_cover-Canis_latrans 1.5983 1.0310 735
## total_shrub_cover-Procyon_lotor -0.3449 1.0141 743
## total_shrub_cover-Dasypus_novemcinctus 0.5045 1.0155 498
## total_shrub_cover-Lynx_rufus -0.1078 1.0079 575
## total_shrub_cover-Didelphis_virginiana 0.1766 1.0100 593
## total_shrub_cover-Sylvilagus_floridanus 0.0446 1.0337 267
## total_shrub_cover-Meleagris_gallopavo -0.2123 1.0089 521
## total_shrub_cover-Sciurus_carolinensis 0.2764 1.0177 380
## avg_veg_height-Canis_latrans 1.1717 1.0067 562
## avg_veg_height-Procyon_lotor 1.1981 1.0095 763
## avg_veg_height-Dasypus_novemcinctus 1.4829 1.0159 653
## avg_veg_height-Lynx_rufus 1.3464 1.0057 651
## avg_veg_height-Didelphis_virginiana 1.0775 1.0105 593
## avg_veg_height-Sylvilagus_floridanus 1.2296 1.0099 562
## avg_veg_height-Meleagris_gallopavo 1.2487 1.0163 396
## avg_veg_height-Sciurus_carolinensis 1.8027 1.0120 986
##
## Detection (logit scale):
## Mean SD 2.5% 50% 97.5% Rhat
## (Intercept)-Canis_latrans -2.6141 0.2051 -3.0435 -2.6095 -2.2360 1.0182
## (Intercept)-Procyon_lotor -2.2091 0.1512 -2.5103 -2.2086 -1.9213 1.0005
## (Intercept)-Dasypus_novemcinctus -1.7655 0.2019 -2.1706 -1.7617 -1.3862 1.0047
## (Intercept)-Lynx_rufus -3.2814 0.3230 -3.9386 -3.2700 -2.6731 1.0105
## (Intercept)-Didelphis_virginiana -2.6027 0.3196 -3.2567 -2.5950 -2.0065 1.0063
## (Intercept)-Sylvilagus_floridanus -3.1186 0.2800 -3.6769 -3.1192 -2.5751 1.0104
## (Intercept)-Meleagris_gallopavo -3.3472 0.5204 -4.4094 -3.3242 -2.4091 1.0324
## (Intercept)-Sciurus_carolinensis -2.7261 0.3417 -3.4108 -2.7223 -2.0772 1.0073
## shrub_cover-Canis_latrans -0.2838 0.2443 -0.7466 -0.2894 0.2106 1.0086
## shrub_cover-Procyon_lotor 0.3266 0.1599 0.0036 0.3297 0.6278 1.0039
## shrub_cover-Dasypus_novemcinctus 1.1615 0.3678 0.4424 1.1668 1.8362 1.0172
## shrub_cover-Lynx_rufus 0.1935 0.3578 -0.5371 0.2151 0.8443 1.0022
## shrub_cover-Didelphis_virginiana 1.3250 0.4245 0.5065 1.3264 2.1773 1.0488
## shrub_cover-Sylvilagus_floridanus 0.7955 0.4139 -0.0799 0.8112 1.5612 1.0187
## shrub_cover-Meleagris_gallopavo -0.2804 0.4814 -1.2486 -0.2622 0.6080 1.0248
## shrub_cover-Sciurus_carolinensis 1.2827 0.4385 0.4016 1.2825 2.1472 1.0078
## veg_height-Canis_latrans -0.5960 0.2023 -1.0038 -0.5885 -0.2204 1.0469
## veg_height-Procyon_lotor 0.3443 0.1214 0.1142 0.3439 0.5842 1.0019
## veg_height-Dasypus_novemcinctus 0.2903 0.1422 0.0175 0.2870 0.5755 1.0010
## veg_height-Lynx_rufus 0.0518 0.2488 -0.4421 0.0589 0.5273 1.0113
## veg_height-Didelphis_virginiana 0.4609 0.2605 -0.0274 0.4557 0.9943 1.0147
## veg_height-Sylvilagus_floridanus 0.0769 0.2552 -0.4264 0.0717 0.5896 1.0150
## veg_height-Meleagris_gallopavo -0.0596 0.4834 -1.0224 -0.0525 0.9217 1.0244
## veg_height-Sciurus_carolinensis 0.1282 0.2306 -0.3185 0.1230 0.5903 1.0047
## week-Canis_latrans 0.4668 0.2485 0.0143 0.4587 0.9910 1.0002
## week-Procyon_lotor 0.1584 0.1976 -0.2384 0.1598 0.5416 1.0015
## week-Dasypus_novemcinctus 0.0570 0.2151 -0.3696 0.0599 0.4749 1.0083
## week-Lynx_rufus 0.2728 0.2933 -0.2809 0.2739 0.8588 1.0089
## week-Didelphis_virginiana 0.0617 0.3155 -0.5929 0.0687 0.6557 1.0010
## week-Sylvilagus_floridanus 0.0702 0.2921 -0.5272 0.0809 0.6347 1.0155
## week-Meleagris_gallopavo -0.0834 0.3502 -0.8427 -0.0628 0.5421 1.0190
## week-Sciurus_carolinensis 0.5579 0.3329 -0.0303 0.5411 1.2644 1.0034
## I(week^2)-Canis_latrans -0.1993 0.1076 -0.4197 -0.1951 0.0007 1.0012
## I(week^2)-Procyon_lotor -0.1127 0.0882 -0.2899 -0.1095 0.0554 1.0018
## I(week^2)-Dasypus_novemcinctus -0.1524 0.1035 -0.3685 -0.1483 0.0451 1.0076
## I(week^2)-Lynx_rufus -0.2035 0.1475 -0.5241 -0.1999 0.0685 1.0034
## I(week^2)-Didelphis_virginiana -0.3889 0.2162 -0.8725 -0.3650 -0.0223 1.0065
## I(week^2)-Sylvilagus_floridanus -0.1698 0.1481 -0.4696 -0.1647 0.1058 1.0099
## I(week^2)-Meleagris_gallopavo -0.3798 0.2433 -0.9805 -0.3487 0.0011 1.0472
## I(week^2)-Sciurus_carolinensis -0.2086 0.1410 -0.4912 -0.2018 0.0491 1.0023
## ESS
## (Intercept)-Canis_latrans 910
## (Intercept)-Procyon_lotor 1786
## (Intercept)-Dasypus_novemcinctus 902
## (Intercept)-Lynx_rufus 666
## (Intercept)-Didelphis_virginiana 517
## (Intercept)-Sylvilagus_floridanus 562
## (Intercept)-Meleagris_gallopavo 258
## (Intercept)-Sciurus_carolinensis 453
## shrub_cover-Canis_latrans 710
## shrub_cover-Procyon_lotor 1981
## shrub_cover-Dasypus_novemcinctus 516
## shrub_cover-Lynx_rufus 737
## shrub_cover-Didelphis_virginiana 389
## shrub_cover-Sylvilagus_floridanus 250
## shrub_cover-Meleagris_gallopavo 358
## shrub_cover-Sciurus_carolinensis 332
## veg_height-Canis_latrans 756
## veg_height-Procyon_lotor 2125
## veg_height-Dasypus_novemcinctus 2255
## veg_height-Lynx_rufus 940
## veg_height-Didelphis_virginiana 816
## veg_height-Sylvilagus_floridanus 805
## veg_height-Meleagris_gallopavo 390
## veg_height-Sciurus_carolinensis 1216
## week-Canis_latrans 1232
## week-Procyon_lotor 1764
## week-Dasypus_novemcinctus 2328
## week-Lynx_rufus 1398
## week-Didelphis_virginiana 1199
## week-Sylvilagus_floridanus 1410
## week-Meleagris_gallopavo 1004
## week-Sciurus_carolinensis 1195
## I(week^2)-Canis_latrans 1400
## I(week^2)-Procyon_lotor 1658
## I(week^2)-Dasypus_novemcinctus 2106
## I(week^2)-Lynx_rufus 1144
## I(week^2)-Didelphis_virginiana 522
## I(week^2)-Sylvilagus_floridanus 859
## I(week^2)-Meleagris_gallopavo 322
## I(week^2)-Sciurus_carolinensis 1423
#Includes quadratic week and full covariates of detection and only foraging for occupancy
ms_fullQ_forage<- msPGOcc(
occ.formula = occ.forage,
det.formula = det.full.quad,
data = data_list,
n.samples = 5000,
n.thin = 2,
n.burn = 3000,
n.chains = 4,
n.report = 500,
)
## ----------------------------------------
## Preparing to run the model
## ----------------------------------------
## Warning in (function (..., row.names = NULL, check.rows = FALSE, check.names =
## TRUE, : row names were found from a short variable and have been discarded
## No prior specified for beta.comm.normal.
## Setting prior mean to 0 and prior variance to 2.72
## No prior specified for alpha.comm.normal.
## Setting prior mean to 0 and prior variance to 2.72
## No prior specified for tau.sq.beta.ig.
## Setting prior shape to 0.1 and prior scale to 0.1
## No prior specified for tau.sq.alpha.ig.
## Setting prior shape to 0.1 and prior scale to 0.1
## No prior specified for sigma.sq.psi.ig.
## Setting prior shape to 0.1 and prior scale to 0.1
## z is not specified in initial values.
## Setting initial values based on observed data
## beta.comm is not specified in initial values.
## Setting initial values to random values from the prior distribution
## alpha.comm is not specified in initial values.
## Setting initial values to random values from the prior distribution
## tau.sq.beta is not specified in initial values.
## Setting initial values to random values between 0.5 and 10
## tau.sq.alpha is not specified in initial values.
## Setting to initial values to random values between 0.5 and 10
## beta is not specified in initial values.
## Setting initial values to random values from the community-level normal distribution
## alpha is not specified in initial values.
## Setting initial values to random values from the community-level normal distribution
## sigma.sq.psi is not specified in initial values.
## Setting initial values to random values between 0.5 and 10
## ----------------------------------------
## Model description
## ----------------------------------------
## Multi-species Occupancy Model with Polya-Gamma latent
## variable fit with 32 sites and 8 species.
##
## Samples per Chain: 5000
## Burn-in: 3000
## Thinning Rate: 2
## Number of Chains: 4
## Total Posterior Samples: 4000
##
## Source compiled with OpenMP support and model fit using 1 thread(s).
##
## ----------------------------------------
## Chain 1
## ----------------------------------------
## Sampling ...
## Sampled: 500 of 5000, 10.00%
## -------------------------------------------------
## Sampled: 1000 of 5000, 20.00%
## -------------------------------------------------
## Sampled: 1500 of 5000, 30.00%
## -------------------------------------------------
## Sampled: 2000 of 5000, 40.00%
## -------------------------------------------------
## Sampled: 2500 of 5000, 50.00%
## -------------------------------------------------
## Sampled: 3000 of 5000, 60.00%
## -------------------------------------------------
## Sampled: 3500 of 5000, 70.00%
## -------------------------------------------------
## Sampled: 4000 of 5000, 80.00%
## -------------------------------------------------
## Sampled: 4500 of 5000, 90.00%
## -------------------------------------------------
## Sampled: 5000 of 5000, 100.00%
## ----------------------------------------
## Chain 2
## ----------------------------------------
## Sampling ...
## Sampled: 500 of 5000, 10.00%
## -------------------------------------------------
## Sampled: 1000 of 5000, 20.00%
## -------------------------------------------------
## Sampled: 1500 of 5000, 30.00%
## -------------------------------------------------
## Sampled: 2000 of 5000, 40.00%
## -------------------------------------------------
## Sampled: 2500 of 5000, 50.00%
## -------------------------------------------------
## Sampled: 3000 of 5000, 60.00%
## -------------------------------------------------
## Sampled: 3500 of 5000, 70.00%
## -------------------------------------------------
## Sampled: 4000 of 5000, 80.00%
## -------------------------------------------------
## Sampled: 4500 of 5000, 90.00%
## -------------------------------------------------
## Sampled: 5000 of 5000, 100.00%
## ----------------------------------------
## Chain 3
## ----------------------------------------
## Sampling ...
## Sampled: 500 of 5000, 10.00%
## -------------------------------------------------
## Sampled: 1000 of 5000, 20.00%
## -------------------------------------------------
## Sampled: 1500 of 5000, 30.00%
## -------------------------------------------------
## Sampled: 2000 of 5000, 40.00%
## -------------------------------------------------
## Sampled: 2500 of 5000, 50.00%
## -------------------------------------------------
## Sampled: 3000 of 5000, 60.00%
## -------------------------------------------------
## Sampled: 3500 of 5000, 70.00%
## -------------------------------------------------
## Sampled: 4000 of 5000, 80.00%
## -------------------------------------------------
## Sampled: 4500 of 5000, 90.00%
## -------------------------------------------------
## Sampled: 5000 of 5000, 100.00%
## ----------------------------------------
## Chain 4
## ----------------------------------------
## Sampling ...
## Sampled: 500 of 5000, 10.00%
## -------------------------------------------------
## Sampled: 1000 of 5000, 20.00%
## -------------------------------------------------
## Sampled: 1500 of 5000, 30.00%
## -------------------------------------------------
## Sampled: 2000 of 5000, 40.00%
## -------------------------------------------------
## Sampled: 2500 of 5000, 50.00%
## -------------------------------------------------
## Sampled: 3000 of 5000, 60.00%
## -------------------------------------------------
## Sampled: 3500 of 5000, 70.00%
## -------------------------------------------------
## Sampled: 4000 of 5000, 80.00%
## -------------------------------------------------
## Sampled: 4500 of 5000, 90.00%
## -------------------------------------------------
## Sampled: 5000 of 5000, 100.00%
summary(ms_fullQ_forage)
##
## Call:
## msPGOcc(occ.formula = occ.forage, det.formula = det.full.quad,
## data = data_list, n.samples = 5000, n.report = 500, n.burn = 3000,
## n.thin = 2, n.chains = 4)
##
## Samples per Chain: 5000
## Burn-in: 3000
## Thinning Rate: 2
## Number of Chains: 4
## Total Posterior Samples: 4000
## Run Time (min): 1.0523
##
## ----------------------------------------
## Community Level
## ----------------------------------------
## Occurrence Means (logit scale):
## Mean SD 2.5% 50% 97.5% Rhat ESS
## (Intercept) -0.3466 0.3711 -1.0978 -0.3503 0.4070 1.0043 749
## Veg_shannon_index 0.3613 0.2720 -0.1765 0.3638 0.8964 1.0085 1218
## Avg_Cogongrass_Cover 0.3414 0.2868 -0.2431 0.3500 0.8853 1.0032 1376
##
## Occurrence Variances (logit scale):
## Mean SD 2.5% 50% 97.5% Rhat ESS
## (Intercept) 0.6114 0.7581 0.0542 0.3955 2.4273 1.0254 1330
## Veg_shannon_index 0.2806 0.3673 0.0362 0.1744 1.1098 1.0127 1744
## Avg_Cogongrass_Cover 0.3412 0.4585 0.0366 0.2016 1.4543 1.0198 1352
##
## Occurrence Random Effect Variances (logit scale):
## Mean SD 2.5% 50% 97.5% Rhat ESS
## Auth 0.7198 0.6703 0.0622 0.5403 2.5253 1.018 380
##
## Detection Means (logit scale):
## Mean SD 2.5% 50% 97.5% Rhat ESS
## (Intercept) -2.6071 0.3317 -3.2465 -2.6074 -1.9353 1.0070 2765
## shrub_cover 0.2562 0.3105 -0.3637 0.2548 0.8755 1.0113 1895
## veg_height 0.0604 0.1986 -0.3482 0.0604 0.4400 1.0034 1591
## week 0.1885 0.2082 -0.2273 0.1902 0.5827 1.0041 1685
## I(week^2) -0.2155 0.1186 -0.4660 -0.2120 0.0083 1.0072 1107
##
## Detection Variances (logit scale):
## Mean SD 2.5% 50% 97.5% Rhat ESS
## (Intercept) 0.7778 0.8311 0.1747 0.5813 2.4756 1.0892 1228
## shrub_cover 0.7010 0.6452 0.1367 0.5373 2.3948 1.0113 1132
## veg_height 0.2575 0.2509 0.0595 0.1912 0.8716 1.0035 2283
## week 0.2032 0.2164 0.0340 0.1371 0.7717 1.0254 1755
## I(week^2) 0.0782 0.0689 0.0199 0.0578 0.2562 1.0074 1049
##
## ----------------------------------------
## Species Level
## ----------------------------------------
## Occurrence (logit scale):
## Mean SD 2.5% 50%
## (Intercept)-Canis_latrans 0.0463 0.5295 -0.9313 0.0135
## (Intercept)-Procyon_lotor 0.1711 0.5557 -0.8690 0.1484
## (Intercept)-Dasypus_novemcinctus -0.5355 0.4810 -1.5264 -0.5184
## (Intercept)-Lynx_rufus -0.2188 0.6098 -1.3413 -0.2503
## (Intercept)-Didelphis_virginiana -0.9021 0.5406 -2.0207 -0.8766
## (Intercept)-Sylvilagus_floridanus -0.4184 0.5197 -1.4247 -0.4321
## (Intercept)-Meleagris_gallopavo -0.1360 0.6476 -1.2825 -0.1965
## (Intercept)-Sciurus_carolinensis -0.8702 0.5462 -2.0480 -0.8407
## Veg_shannon_index-Canis_latrans 0.6290 0.3840 -0.0685 0.6096
## Veg_shannon_index-Procyon_lotor 0.4568 0.3563 -0.2321 0.4531
## Veg_shannon_index-Dasypus_novemcinctus 0.1882 0.3382 -0.4970 0.1987
## Veg_shannon_index-Lynx_rufus 0.2280 0.4575 -0.7267 0.2406
## Veg_shannon_index-Didelphis_virginiana 0.4845 0.3852 -0.2111 0.4603
## Veg_shannon_index-Sylvilagus_floridanus 0.4250 0.3959 -0.3203 0.4222
## Veg_shannon_index-Meleagris_gallopavo 0.5165 0.4609 -0.3575 0.4948
## Veg_shannon_index-Sciurus_carolinensis 0.0039 0.4050 -0.9001 0.0366
## Avg_Cogongrass_Cover-Canis_latrans 0.6091 0.4080 -0.0955 0.5733
## Avg_Cogongrass_Cover-Procyon_lotor 0.3642 0.3635 -0.3184 0.3530
## Avg_Cogongrass_Cover-Dasypus_novemcinctus 0.4529 0.3426 -0.1917 0.4481
## Avg_Cogongrass_Cover-Lynx_rufus 0.5720 0.4324 -0.1910 0.5342
## Avg_Cogongrass_Cover-Didelphis_virginiana 0.4532 0.3672 -0.2379 0.4345
## Avg_Cogongrass_Cover-Sylvilagus_floridanus -0.0785 0.4701 -1.1704 -0.0286
## Avg_Cogongrass_Cover-Meleagris_gallopavo -0.0251 0.5929 -1.3828 0.0349
## Avg_Cogongrass_Cover-Sciurus_carolinensis 0.4267 0.3657 -0.2597 0.4254
## 97.5% Rhat ESS
## (Intercept)-Canis_latrans 1.1374 1.0035 1179
## (Intercept)-Procyon_lotor 1.3203 1.0049 803
## (Intercept)-Dasypus_novemcinctus 0.3867 1.0017 1722
## (Intercept)-Lynx_rufus 1.0963 1.0131 812
## (Intercept)-Didelphis_virginiana 0.0774 1.0028 1112
## (Intercept)-Sylvilagus_floridanus 0.6565 1.0068 1303
## (Intercept)-Meleagris_gallopavo 1.2848 1.0095 613
## (Intercept)-Sciurus_carolinensis 0.0942 1.0044 1268
## Veg_shannon_index-Canis_latrans 1.4526 1.0030 1672
## Veg_shannon_index-Procyon_lotor 1.1762 1.0049 2162
## Veg_shannon_index-Dasypus_novemcinctus 0.8386 1.0006 2323
## Veg_shannon_index-Lynx_rufus 1.1015 1.0026 1574
## Veg_shannon_index-Didelphis_virginiana 1.3090 1.0051 2253
## Veg_shannon_index-Sylvilagus_floridanus 1.2576 1.0081 1906
## Veg_shannon_index-Meleagris_gallopavo 1.5386 1.0012 1535
## Veg_shannon_index-Sciurus_carolinensis 0.7102 1.0018 1966
## Avg_Cogongrass_Cover-Canis_latrans 1.4883 1.0025 1896
## Avg_Cogongrass_Cover-Procyon_lotor 1.1208 1.0015 2690
## Avg_Cogongrass_Cover-Dasypus_novemcinctus 1.1425 1.0027 2721
## Avg_Cogongrass_Cover-Lynx_rufus 1.5553 1.0062 1608
## Avg_Cogongrass_Cover-Didelphis_virginiana 1.1978 1.0016 2398
## Avg_Cogongrass_Cover-Sylvilagus_floridanus 0.7149 1.0056 1191
## Avg_Cogongrass_Cover-Meleagris_gallopavo 1.0085 1.0059 760
## Avg_Cogongrass_Cover-Sciurus_carolinensis 1.1817 1.0084 2151
##
## Detection (logit scale):
## Mean SD 2.5% 50% 97.5% Rhat
## (Intercept)-Canis_latrans -2.5657 0.1957 -2.9630 -2.5579 -2.2002 1.0009
## (Intercept)-Procyon_lotor -2.2073 0.1624 -2.5336 -2.2034 -1.9028 1.0035
## (Intercept)-Dasypus_novemcinctus -1.6434 0.1817 -2.0020 -1.6419 -1.3021 1.0038
## (Intercept)-Lynx_rufus -3.3972 0.3432 -4.1136 -3.3845 -2.7381 1.0233
## (Intercept)-Didelphis_virginiana -2.4035 0.2952 -3.0138 -2.3941 -1.8619 1.0137
## (Intercept)-Sylvilagus_floridanus -3.0454 0.2993 -3.6852 -3.0376 -2.4787 1.0085
## (Intercept)-Meleagris_gallopavo -3.7211 0.4857 -4.7479 -3.7020 -2.7779 1.0591
## (Intercept)-Sciurus_carolinensis -2.5335 0.3187 -3.1993 -2.5239 -1.9401 1.0024
## shrub_cover-Canis_latrans -0.2853 0.2142 -0.7093 -0.2822 0.1252 1.0055
## shrub_cover-Procyon_lotor 0.2465 0.1667 -0.0929 0.2513 0.5653 1.0026
## shrub_cover-Dasypus_novemcinctus 0.8720 0.2991 0.3078 0.8674 1.4698 1.0050
## shrub_cover-Lynx_rufus -0.2022 0.3539 -0.8889 -0.2069 0.5135 1.0120
## shrub_cover-Didelphis_virginiana 0.9893 0.3859 0.2747 0.9737 1.7728 1.0024
## shrub_cover-Sylvilagus_floridanus 0.2744 0.4215 -0.5340 0.2594 1.1435 1.0195
## shrub_cover-Meleagris_gallopavo -0.6669 0.4213 -1.5407 -0.6508 0.1370 1.0540
## shrub_cover-Sciurus_carolinensis 0.8863 0.4111 0.1040 0.8724 1.7311 1.0083
## veg_height-Canis_latrans -0.5815 0.1868 -0.9635 -0.5735 -0.2297 1.0007
## veg_height-Procyon_lotor 0.3395 0.1225 0.1050 0.3390 0.5738 1.0019
## veg_height-Dasypus_novemcinctus 0.2558 0.1339 -0.0070 0.2533 0.5261 1.0055
## veg_height-Lynx_rufus 0.0217 0.2556 -0.5194 0.0326 0.5084 1.0084
## veg_height-Didelphis_virginiana 0.4379 0.2399 -0.0120 0.4296 0.9158 1.0015
## veg_height-Sylvilagus_floridanus 0.1535 0.2481 -0.3277 0.1502 0.6326 1.0044
## veg_height-Meleagris_gallopavo -0.1970 0.3860 -0.9476 -0.1993 0.5777 1.0231
## veg_height-Sciurus_carolinensis 0.0882 0.2141 -0.3223 0.0819 0.5150 1.0025
## week-Canis_latrans 0.4493 0.2461 -0.0165 0.4460 0.9557 1.0030
## week-Procyon_lotor 0.1562 0.1996 -0.2346 0.1530 0.5525 1.0032
## week-Dasypus_novemcinctus 0.0722 0.2079 -0.3417 0.0725 0.4701 1.0039
## week-Lynx_rufus 0.2807 0.2990 -0.2886 0.2714 0.8867 1.0014
## week-Didelphis_virginiana 0.0654 0.3118 -0.5861 0.0710 0.6548 1.0026
## week-Sylvilagus_floridanus 0.0514 0.3000 -0.5463 0.0557 0.6331 1.0036
## week-Meleagris_gallopavo -0.0755 0.3487 -0.8385 -0.0568 0.5492 1.0138
## week-Sciurus_carolinensis 0.5393 0.3310 -0.0320 0.5160 1.2554 1.0039
## I(week^2)-Canis_latrans -0.1953 0.1036 -0.4019 -0.1940 0.0065 1.0021
## I(week^2)-Procyon_lotor -0.1106 0.0880 -0.2854 -0.1088 0.0638 1.0008
## I(week^2)-Dasypus_novemcinctus -0.1589 0.0995 -0.3616 -0.1582 0.0337 1.0046
## I(week^2)-Lynx_rufus -0.1966 0.1452 -0.5006 -0.1880 0.0692 1.0112
## I(week^2)-Didelphis_virginiana -0.3509 0.2122 -0.8712 -0.3239 -0.0083 1.0168
## I(week^2)-Sylvilagus_floridanus -0.1563 0.1485 -0.4641 -0.1481 0.1176 1.0130
## I(week^2)-Meleagris_gallopavo -0.3819 0.2363 -0.9524 -0.3509 -0.0047 1.0141
## I(week^2)-Sciurus_carolinensis -0.1927 0.1381 -0.4911 -0.1862 0.0587 1.0037
## ESS
## (Intercept)-Canis_latrans 1202
## (Intercept)-Procyon_lotor 1739
## (Intercept)-Dasypus_novemcinctus 1925
## (Intercept)-Lynx_rufus 488
## (Intercept)-Didelphis_virginiana 1230
## (Intercept)-Sylvilagus_floridanus 625
## (Intercept)-Meleagris_gallopavo 326
## (Intercept)-Sciurus_carolinensis 1202
## shrub_cover-Canis_latrans 1357
## shrub_cover-Procyon_lotor 1775
## shrub_cover-Dasypus_novemcinctus 1628
## shrub_cover-Lynx_rufus 691
## shrub_cover-Didelphis_virginiana 971
## shrub_cover-Sylvilagus_floridanus 733
## shrub_cover-Meleagris_gallopavo 335
## shrub_cover-Sciurus_carolinensis 1027
## veg_height-Canis_latrans 950
## veg_height-Procyon_lotor 2507
## veg_height-Dasypus_novemcinctus 2237
## veg_height-Lynx_rufus 745
## veg_height-Didelphis_virginiana 1668
## veg_height-Sylvilagus_floridanus 1163
## veg_height-Meleagris_gallopavo 660
## veg_height-Sciurus_carolinensis 1440
## week-Canis_latrans 1741
## week-Procyon_lotor 2234
## week-Dasypus_novemcinctus 2054
## week-Lynx_rufus 1527
## week-Didelphis_virginiana 1445
## week-Sylvilagus_floridanus 1465
## week-Meleagris_gallopavo 896
## week-Sciurus_carolinensis 1586
## I(week^2)-Canis_latrans 1637
## I(week^2)-Procyon_lotor 2196
## I(week^2)-Dasypus_novemcinctus 2322
## I(week^2)-Lynx_rufus 1084
## I(week^2)-Didelphis_virginiana 605
## I(week^2)-Sylvilagus_floridanus 996
## I(week^2)-Meleagris_gallopavo 304
## I(week^2)-Sciurus_carolinensis 1655
# Includes quadratic week and full covariates of detection and all covariates and quadratic cogon for occupancy
ms_fullQ_fullQ<- msPGOcc(
occ.formula = occ.full.quad,
det.formula = det.full.quad,
data = data_list,
n.samples = 5000,
n.thin = 2,
n.burn = 3000,
n.chains = 4,
n.report = 500,
)
## ----------------------------------------
## Preparing to run the model
## ----------------------------------------
## Warning in (function (..., row.names = NULL, check.rows = FALSE, check.names =
## TRUE, : row names were found from a short variable and have been discarded
## No prior specified for beta.comm.normal.
## Setting prior mean to 0 and prior variance to 2.72
## No prior specified for alpha.comm.normal.
## Setting prior mean to 0 and prior variance to 2.72
## No prior specified for tau.sq.beta.ig.
## Setting prior shape to 0.1 and prior scale to 0.1
## No prior specified for tau.sq.alpha.ig.
## Setting prior shape to 0.1 and prior scale to 0.1
## No prior specified for sigma.sq.psi.ig.
## Setting prior shape to 0.1 and prior scale to 0.1
## z is not specified in initial values.
## Setting initial values based on observed data
## beta.comm is not specified in initial values.
## Setting initial values to random values from the prior distribution
## alpha.comm is not specified in initial values.
## Setting initial values to random values from the prior distribution
## tau.sq.beta is not specified in initial values.
## Setting initial values to random values between 0.5 and 10
## tau.sq.alpha is not specified in initial values.
## Setting to initial values to random values between 0.5 and 10
## beta is not specified in initial values.
## Setting initial values to random values from the community-level normal distribution
## alpha is not specified in initial values.
## Setting initial values to random values from the community-level normal distribution
## sigma.sq.psi is not specified in initial values.
## Setting initial values to random values between 0.5 and 10
## ----------------------------------------
## Model description
## ----------------------------------------
## Multi-species Occupancy Model with Polya-Gamma latent
## variable fit with 32 sites and 8 species.
##
## Samples per Chain: 5000
## Burn-in: 3000
## Thinning Rate: 2
## Number of Chains: 4
## Total Posterior Samples: 4000
##
## Source compiled with OpenMP support and model fit using 1 thread(s).
##
## ----------------------------------------
## Chain 1
## ----------------------------------------
## Sampling ...
## Sampled: 500 of 5000, 10.00%
## -------------------------------------------------
## Sampled: 1000 of 5000, 20.00%
## -------------------------------------------------
## Sampled: 1500 of 5000, 30.00%
## -------------------------------------------------
## Sampled: 2000 of 5000, 40.00%
## -------------------------------------------------
## Sampled: 2500 of 5000, 50.00%
## -------------------------------------------------
## Sampled: 3000 of 5000, 60.00%
## -------------------------------------------------
## Sampled: 3500 of 5000, 70.00%
## -------------------------------------------------
## Sampled: 4000 of 5000, 80.00%
## -------------------------------------------------
## Sampled: 4500 of 5000, 90.00%
## -------------------------------------------------
## Sampled: 5000 of 5000, 100.00%
## ----------------------------------------
## Chain 2
## ----------------------------------------
## Sampling ...
## Sampled: 500 of 5000, 10.00%
## -------------------------------------------------
## Sampled: 1000 of 5000, 20.00%
## -------------------------------------------------
## Sampled: 1500 of 5000, 30.00%
## -------------------------------------------------
## Sampled: 2000 of 5000, 40.00%
## -------------------------------------------------
## Sampled: 2500 of 5000, 50.00%
## -------------------------------------------------
## Sampled: 3000 of 5000, 60.00%
## -------------------------------------------------
## Sampled: 3500 of 5000, 70.00%
## -------------------------------------------------
## Sampled: 4000 of 5000, 80.00%
## -------------------------------------------------
## Sampled: 4500 of 5000, 90.00%
## -------------------------------------------------
## Sampled: 5000 of 5000, 100.00%
## ----------------------------------------
## Chain 3
## ----------------------------------------
## Sampling ...
## Sampled: 500 of 5000, 10.00%
## -------------------------------------------------
## Sampled: 1000 of 5000, 20.00%
## -------------------------------------------------
## Sampled: 1500 of 5000, 30.00%
## -------------------------------------------------
## Sampled: 2000 of 5000, 40.00%
## -------------------------------------------------
## Sampled: 2500 of 5000, 50.00%
## -------------------------------------------------
## Sampled: 3000 of 5000, 60.00%
## -------------------------------------------------
## Sampled: 3500 of 5000, 70.00%
## -------------------------------------------------
## Sampled: 4000 of 5000, 80.00%
## -------------------------------------------------
## Sampled: 4500 of 5000, 90.00%
## -------------------------------------------------
## Sampled: 5000 of 5000, 100.00%
## ----------------------------------------
## Chain 4
## ----------------------------------------
## Sampling ...
## Sampled: 500 of 5000, 10.00%
## -------------------------------------------------
## Sampled: 1000 of 5000, 20.00%
## -------------------------------------------------
## Sampled: 1500 of 5000, 30.00%
## -------------------------------------------------
## Sampled: 2000 of 5000, 40.00%
## -------------------------------------------------
## Sampled: 2500 of 5000, 50.00%
## -------------------------------------------------
## Sampled: 3000 of 5000, 60.00%
## -------------------------------------------------
## Sampled: 3500 of 5000, 70.00%
## -------------------------------------------------
## Sampled: 4000 of 5000, 80.00%
## -------------------------------------------------
## Sampled: 4500 of 5000, 90.00%
## -------------------------------------------------
## Sampled: 5000 of 5000, 100.00%
summary(ms_fullQ_fullQ)
##
## Call:
## msPGOcc(occ.formula = occ.full.quad, det.formula = det.full.quad,
## data = data_list, n.samples = 5000, n.report = 500, n.burn = 3000,
## n.thin = 2, n.chains = 4)
##
## Samples per Chain: 5000
## Burn-in: 3000
## Thinning Rate: 2
## Number of Chains: 4
## Total Posterior Samples: 4000
## Run Time (min): 1.0865
##
## ----------------------------------------
## Community Level
## ----------------------------------------
## Occurrence Means (logit scale):
## Mean SD 2.5% 50% 97.5% Rhat ESS
## (Intercept) -1.8388 0.7039 -3.1840 -1.8605 -0.4530 1.0188 500
## Cogon_Patch_Size 0.1097 0.7146 -1.2957 0.1074 1.5175 1.0287 551
## Veg_shannon_index 0.9644 0.4977 0.0036 0.9443 2.0175 1.0221 315
## total_shrub_cover -1.1179 0.6624 -2.5421 -1.0822 0.0835 1.0292 562
## Avg_Cogongrass_Cover 0.0222 1.0082 -2.0320 0.0630 1.9060 1.0566 211
## Tree_Density -2.2349 0.9728 -4.0900 -2.2625 -0.2417 1.0125 253
## Avg_Canopy_Cover 1.8674 0.8003 0.3528 1.8306 3.6120 1.0065 746
## I(Avg_Cogongrass_Cover^2) 1.4121 0.6728 0.0686 1.4083 2.7513 1.0209 403
## avg_veg_height -0.0632 0.5771 -1.2023 -0.0622 1.0266 1.0214 289
##
## Occurrence Variances (logit scale):
## Mean SD 2.5% 50% 97.5% Rhat ESS
## (Intercept) 1.8980 3.6816 0.0681 0.8919 9.6473 1.0501 647
## Cogon_Patch_Size 2.7732 5.0636 0.0915 1.3619 13.8502 1.0760 656
## Veg_shannon_index 0.7404 1.1263 0.0481 0.3821 3.7679 1.0306 674
## total_shrub_cover 2.5130 3.8935 0.1026 1.4186 11.9953 1.1475 375
## Avg_Cogongrass_Cover 1.3452 2.6643 0.0464 0.5367 7.7310 1.0122 689
## Tree_Density 3.8679 7.6623 0.0710 1.4453 23.7704 1.0182 221
## Avg_Canopy_Cover 4.5569 7.2386 0.2118 2.4256 21.4766 1.0274 362
## I(Avg_Cogongrass_Cover^2) 2.5707 5.8501 0.0754 1.1800 13.1664 1.3653 265
## avg_veg_height 0.8130 1.6438 0.0494 0.3536 4.1707 1.0435 656
##
## Occurrence Random Effect Variances (logit scale):
## Mean SD 2.5% 50% 97.5% Rhat ESS
## Auth 1.682 2.3209 0.0554 0.8193 8.2776 1.0567 83
##
## Detection Means (logit scale):
## Mean SD 2.5% 50% 97.5% Rhat ESS
## (Intercept) -2.6221 0.2947 -3.1963 -2.6250 -2.0351 1.0039 2771
## shrub_cover 0.4348 0.3109 -0.1693 0.4343 1.0594 1.0035 1671
## veg_height 0.1317 0.2040 -0.2789 0.1353 0.5216 1.0013 1201
## week 0.1844 0.2002 -0.2163 0.1855 0.5788 1.0025 1617
## I(week^2) -0.2196 0.1206 -0.4760 -0.2152 0.0086 1.0115 1460
##
## Detection Variances (logit scale):
## Mean SD 2.5% 50% 97.5% Rhat ESS
## (Intercept) 0.6397 0.5543 0.1449 0.4879 2.1182 1.0082 1580
## shrub_cover 0.6965 0.6673 0.1312 0.5152 2.2857 1.0069 1183
## veg_height 0.2593 0.2499 0.0587 0.1935 0.8639 1.0132 1673
## week 0.1964 0.2288 0.0334 0.1367 0.7116 1.0038 1302
## I(week^2) 0.0824 0.0913 0.0192 0.0594 0.2802 1.0390 956
##
## ----------------------------------------
## Species Level
## ----------------------------------------
## Occurrence (logit scale):
## Mean SD 2.5% 50%
## (Intercept)-Canis_latrans -1.4612 0.9647 -3.3065 -1.4979
## (Intercept)-Procyon_lotor -1.1199 0.9781 -2.9379 -1.1539
## (Intercept)-Dasypus_novemcinctus -2.2087 0.9282 -4.1465 -2.1435
## (Intercept)-Lynx_rufus -1.4972 1.2119 -3.6189 -1.5991
## (Intercept)-Didelphis_virginiana -2.7444 1.1605 -5.5359 -2.5854
## (Intercept)-Sylvilagus_floridanus -1.9893 1.0303 -4.2285 -1.9389
## (Intercept)-Meleagris_gallopavo -1.8181 1.1133 -3.8852 -1.8504
## (Intercept)-Sciurus_carolinensis -2.9478 1.2533 -5.9004 -2.7642
## Cogon_Patch_Size-Canis_latrans 1.3757 1.2784 -0.4889 1.1466
## Cogon_Patch_Size-Procyon_lotor -0.4773 0.8284 -2.2359 -0.4172
## Cogon_Patch_Size-Dasypus_novemcinctus 0.1317 0.8402 -1.4307 0.1084
## Cogon_Patch_Size-Lynx_rufus -0.0556 1.3817 -2.7740 -0.0997
## Cogon_Patch_Size-Didelphis_virginiana 1.3666 1.0644 -0.3346 1.2328
## Cogon_Patch_Size-Sylvilagus_floridanus -0.9918 1.4255 -4.5041 -0.7741
## Cogon_Patch_Size-Meleagris_gallopavo 0.3573 1.2836 -1.7487 0.2207
## Cogon_Patch_Size-Sciurus_carolinensis -0.7006 1.1886 -3.4262 -0.5378
## Veg_shannon_index-Canis_latrans 1.3162 0.7290 0.0680 1.2510
## Veg_shannon_index-Procyon_lotor 1.1873 0.6328 0.0716 1.1375
## Veg_shannon_index-Dasypus_novemcinctus 0.6164 0.6101 -0.5866 0.6286
## Veg_shannon_index-Lynx_rufus 0.9664 0.8642 -0.6537 0.9252
## Veg_shannon_index-Didelphis_virginiana 1.1598 0.7318 -0.1059 1.1042
## Veg_shannon_index-Sylvilagus_floridanus 1.0592 0.7586 -0.2864 1.0121
## Veg_shannon_index-Meleagris_gallopavo 1.2742 0.8309 -0.1107 1.1932
## Veg_shannon_index-Sciurus_carolinensis 0.3958 0.8080 -1.3944 0.4636
## total_shrub_cover-Canis_latrans 0.1819 0.8803 -1.3615 0.0971
## total_shrub_cover-Procyon_lotor -1.5190 0.7477 -3.1525 -1.4495
## total_shrub_cover-Dasypus_novemcinctus -0.5127 0.8741 -2.4577 -0.4475
## total_shrub_cover-Lynx_rufus -1.9368 1.3047 -4.9284 -1.7492
## total_shrub_cover-Didelphis_virginiana -1.3552 1.0591 -3.7713 -1.2379
## total_shrub_cover-Sylvilagus_floridanus -1.1617 1.1701 -3.8086 -1.0503
## total_shrub_cover-Meleagris_gallopavo -2.5838 1.5406 -6.1529 -2.3489
## total_shrub_cover-Sciurus_carolinensis -1.1082 1.2118 -3.9932 -0.9704
## Avg_Cogongrass_Cover-Canis_latrans 0.1375 1.2267 -2.2852 0.1665
## Avg_Cogongrass_Cover-Procyon_lotor -0.0710 1.2094 -2.5535 -0.0326
## Avg_Cogongrass_Cover-Dasypus_novemcinctus 0.6007 1.3551 -1.8670 0.5481
## Avg_Cogongrass_Cover-Lynx_rufus 0.0302 1.3146 -2.5422 0.0461
## Avg_Cogongrass_Cover-Didelphis_virginiana 0.1999 1.3260 -2.3778 0.2131
## Avg_Cogongrass_Cover-Sylvilagus_floridanus -0.6011 1.3691 -3.5766 -0.5250
## Avg_Cogongrass_Cover-Meleagris_gallopavo -0.2749 1.4112 -3.3157 -0.1839
## Avg_Cogongrass_Cover-Sciurus_carolinensis 0.1251 1.2545 -2.3162 0.1349
## Tree_Density-Canis_latrans -3.2445 1.5831 -6.9676 -3.0045
## Tree_Density-Procyon_lotor -2.3402 1.1145 -4.6827 -2.3036
## Tree_Density-Dasypus_novemcinctus -4.0305 2.0135 -9.2148 -3.5829
## Tree_Density-Lynx_rufus -1.0467 1.7873 -3.9773 -1.2378
## Tree_Density-Didelphis_virginiana -2.3088 1.2941 -4.9392 -2.2467
## Tree_Density-Sylvilagus_floridanus -2.7936 1.4987 -5.9693 -2.6710
## Tree_Density-Meleagris_gallopavo -2.3564 1.5141 -5.4048 -2.3705
## Tree_Density-Sciurus_carolinensis -2.4134 1.5391 -5.7836 -2.3740
## Avg_Canopy_Cover-Canis_latrans 0.0965 0.7006 -1.3626 0.1022
## Avg_Canopy_Cover-Procyon_lotor 1.6306 0.8442 0.1418 1.5749
## Avg_Canopy_Cover-Dasypus_novemcinctus 2.2923 0.9627 0.7974 2.1772
## Avg_Canopy_Cover-Lynx_rufus 1.0312 1.3821 -1.5235 0.9518
## Avg_Canopy_Cover-Didelphis_virginiana 3.1806 1.3995 1.1679 2.9638
## Avg_Canopy_Cover-Sylvilagus_floridanus 4.0152 2.0001 1.2295 3.6383
## Avg_Canopy_Cover-Meleagris_gallopavo 2.4539 1.3579 0.4919 2.1969
## Avg_Canopy_Cover-Sciurus_carolinensis 3.1201 1.6529 0.9502 2.7602
## I(Avg_Cogongrass_Cover^2)-Canis_latrans 2.3977 1.2869 0.6480 2.1717
## I(Avg_Cogongrass_Cover^2)-Procyon_lotor 2.4398 1.3611 0.6628 2.2036
## I(Avg_Cogongrass_Cover^2)-Dasypus_novemcinctus 1.3992 0.7716 0.0047 1.3382
## I(Avg_Cogongrass_Cover^2)-Lynx_rufus 2.6681 1.3445 0.7840 2.4084
## I(Avg_Cogongrass_Cover^2)-Didelphis_virginiana 0.7956 0.7837 -0.7308 0.7968
## I(Avg_Cogongrass_Cover^2)-Sylvilagus_floridanus 1.0898 0.9116 -0.5264 1.0239
## I(Avg_Cogongrass_Cover^2)-Meleagris_gallopavo 0.2262 1.5128 -3.1665 0.3654
## I(Avg_Cogongrass_Cover^2)-Sciurus_carolinensis 1.4706 0.8375 0.0255 1.3858
## avg_veg_height-Canis_latrans -0.2427 0.6812 -1.6255 -0.2161
## avg_veg_height-Procyon_lotor 0.0670 0.6971 -1.3077 0.0552
## avg_veg_height-Dasypus_novemcinctus 0.3288 0.7008 -0.9392 0.2887
## avg_veg_height-Lynx_rufus -0.4832 1.0406 -2.9428 -0.3618
## avg_veg_height-Didelphis_virginiana -0.2651 0.7989 -1.9855 -0.2179
## avg_veg_height-Sylvilagus_floridanus -0.1966 0.7925 -1.8544 -0.1730
## avg_veg_height-Meleagris_gallopavo -0.1072 1.0131 -2.2708 -0.0751
## avg_veg_height-Sciurus_carolinensis 0.4069 0.8542 -1.0162 0.3177
## 97.5% Rhat ESS
## (Intercept)-Canis_latrans 0.5537 1.0200 424
## (Intercept)-Procyon_lotor 0.8397 1.0268 371
## (Intercept)-Dasypus_novemcinctus -0.6231 1.0427 419
## (Intercept)-Lynx_rufus 1.3552 1.0217 352
## (Intercept)-Didelphis_virginiana -0.9063 1.0120 485
## (Intercept)-Sylvilagus_floridanus -0.0874 1.0232 605
## (Intercept)-Meleagris_gallopavo 0.5151 1.0308 481
## (Intercept)-Sciurus_carolinensis -0.9603 1.0137 402
## Cogon_Patch_Size-Canis_latrans 4.5853 1.0617 541
## Cogon_Patch_Size-Procyon_lotor 0.9717 1.0351 358
## Cogon_Patch_Size-Dasypus_novemcinctus 1.8799 1.0185 795
## Cogon_Patch_Size-Lynx_rufus 2.8100 1.0372 391
## Cogon_Patch_Size-Didelphis_virginiana 3.8112 1.0355 413
## Cogon_Patch_Size-Sylvilagus_floridanus 1.1627 1.0360 439
## Cogon_Patch_Size-Meleagris_gallopavo 3.5373 1.0310 505
## Cogon_Patch_Size-Sciurus_carolinensis 1.2252 1.0237 530
## Veg_shannon_index-Canis_latrans 2.9443 1.0110 607
## Veg_shannon_index-Procyon_lotor 2.5949 1.0101 393
## Veg_shannon_index-Dasypus_novemcinctus 1.8144 1.0083 1009
## Veg_shannon_index-Lynx_rufus 2.7660 1.0214 497
## Veg_shannon_index-Didelphis_virginiana 2.7652 1.0235 633
## Veg_shannon_index-Sylvilagus_floridanus 2.6023 1.0233 432
## Veg_shannon_index-Meleagris_gallopavo 3.1278 1.0222 573
## Veg_shannon_index-Sciurus_carolinensis 1.8402 1.0102 665
## total_shrub_cover-Canis_latrans 2.2742 1.0363 495
## total_shrub_cover-Procyon_lotor -0.2054 1.0034 678
## total_shrub_cover-Dasypus_novemcinctus 0.9854 1.0110 635
## total_shrub_cover-Lynx_rufus 0.1844 1.0587 334
## total_shrub_cover-Didelphis_virginiana 0.3482 1.0105 656
## total_shrub_cover-Sylvilagus_floridanus 0.8228 1.0780 427
## total_shrub_cover-Meleagris_gallopavo -0.2961 1.0796 281
## total_shrub_cover-Sciurus_carolinensis 0.8883 1.0432 357
## Avg_Cogongrass_Cover-Canis_latrans 2.5321 1.0294 295
## Avg_Cogongrass_Cover-Procyon_lotor 2.2334 1.0426 315
## Avg_Cogongrass_Cover-Dasypus_novemcinctus 3.6595 1.0602 255
## Avg_Cogongrass_Cover-Lynx_rufus 2.6212 1.0159 384
## Avg_Cogongrass_Cover-Didelphis_virginiana 2.9102 1.0568 321
## Avg_Cogongrass_Cover-Sylvilagus_floridanus 1.7769 1.0422 296
## Avg_Cogongrass_Cover-Meleagris_gallopavo 2.2053 1.0324 337
## Avg_Cogongrass_Cover-Sciurus_carolinensis 2.6704 1.0391 305
## Tree_Density-Canis_latrans -0.8898 1.0164 262
## Tree_Density-Procyon_lotor -0.3249 1.0263 371
## Tree_Density-Dasypus_novemcinctus -1.3643 1.0119 214
## Tree_Density-Lynx_rufus 3.1789 1.0137 198
## Tree_Density-Didelphis_virginiana 0.1324 1.0024 605
## Tree_Density-Sylvilagus_floridanus -0.2476 1.0085 338
## Tree_Density-Meleagris_gallopavo 0.4739 1.0299 375
## Tree_Density-Sciurus_carolinensis 0.5703 1.0222 352
## Avg_Canopy_Cover-Canis_latrans 1.4526 1.0035 708
## Avg_Canopy_Cover-Procyon_lotor 3.4995 1.0089 330
## Avg_Canopy_Cover-Dasypus_novemcinctus 4.5188 1.0144 382
## Avg_Canopy_Cover-Lynx_rufus 3.9508 1.0311 360
## Avg_Canopy_Cover-Didelphis_virginiana 6.5335 1.0125 325
## Avg_Canopy_Cover-Sylvilagus_floridanus 8.8186 1.0246 228
## Avg_Canopy_Cover-Meleagris_gallopavo 5.8931 1.0177 260
## Avg_Canopy_Cover-Sciurus_carolinensis 7.4120 1.0391 289
## I(Avg_Cogongrass_Cover^2)-Canis_latrans 5.3447 1.1012 239
## I(Avg_Cogongrass_Cover^2)-Procyon_lotor 5.6796 1.1770 228
## I(Avg_Cogongrass_Cover^2)-Dasypus_novemcinctus 3.0459 1.0153 721
## I(Avg_Cogongrass_Cover^2)-Lynx_rufus 6.0419 1.0388 287
## I(Avg_Cogongrass_Cover^2)-Didelphis_virginiana 2.3742 1.0449 327
## I(Avg_Cogongrass_Cover^2)-Sylvilagus_floridanus 3.1155 1.0559 395
## I(Avg_Cogongrass_Cover^2)-Meleagris_gallopavo 2.8144 1.0749 156
## I(Avg_Cogongrass_Cover^2)-Sciurus_carolinensis 3.3243 1.0084 689
## avg_veg_height-Canis_latrans 1.0697 1.0103 525
## avg_veg_height-Procyon_lotor 1.4885 1.0194 521
## avg_veg_height-Dasypus_novemcinctus 1.8386 1.0130 586
## avg_veg_height-Lynx_rufus 1.2262 1.0366 306
## avg_veg_height-Didelphis_virginiana 1.2609 1.0122 553
## avg_veg_height-Sylvilagus_floridanus 1.3267 1.0175 471
## avg_veg_height-Meleagris_gallopavo 1.7760 1.0175 428
## avg_veg_height-Sciurus_carolinensis 2.3835 1.0037 459
##
## Detection (logit scale):
## Mean SD 2.5% 50% 97.5% Rhat
## (Intercept)-Canis_latrans -2.5674 0.1902 -2.9593 -2.5650 -2.2046 1.0058
## (Intercept)-Procyon_lotor -2.2224 0.1610 -2.5405 -2.2200 -1.9132 1.0097
## (Intercept)-Dasypus_novemcinctus -1.7109 0.1873 -2.0857 -1.7060 -1.3577 1.0055
## (Intercept)-Lynx_rufus -3.4535 0.3320 -4.1269 -3.4495 -2.8369 1.0092
## (Intercept)-Didelphis_virginiana -2.4910 0.2922 -3.0670 -2.4931 -1.9078 1.0044
## (Intercept)-Sylvilagus_floridanus -3.0651 0.2749 -3.6484 -3.0535 -2.5686 1.0112
## (Intercept)-Meleagris_gallopavo -3.4161 0.4751 -4.3549 -3.4278 -2.4904 1.0327
## (Intercept)-Sciurus_carolinensis -2.6820 0.3352 -3.3358 -2.6759 -2.0412 1.0027
## shrub_cover-Canis_latrans -0.2897 0.2367 -0.7712 -0.2876 0.1699 1.0021
## shrub_cover-Procyon_lotor 0.2931 0.1624 -0.0362 0.2933 0.6039 0.9998
## shrub_cover-Dasypus_novemcinctus 1.0294 0.3185 0.3902 1.0381 1.6375 1.0041
## shrub_cover-Lynx_rufus 0.0770 0.3568 -0.6265 0.0807 0.7496 1.0258
## shrub_cover-Didelphis_virginiana 1.1253 0.3679 0.4348 1.1155 1.8783 1.0123
## shrub_cover-Sylvilagus_floridanus 0.5914 0.3945 -0.1793 0.5892 1.3560 1.0266
## shrub_cover-Meleagris_gallopavo -0.3542 0.4470 -1.2399 -0.3535 0.5068 1.0325
## shrub_cover-Sciurus_carolinensis 1.1132 0.4195 0.2694 1.1141 1.9208 1.0024
## veg_height-Canis_latrans -0.5496 0.1869 -0.9158 -0.5471 -0.1886 1.0029
## veg_height-Procyon_lotor 0.3734 0.1214 0.1410 0.3726 0.6133 1.0040
## veg_height-Dasypus_novemcinctus 0.2940 0.1373 0.0362 0.2896 0.5661 1.0017
## veg_height-Lynx_rufus 0.1681 0.2422 -0.3144 0.1770 0.6245 1.0142
## veg_height-Didelphis_virginiana 0.5068 0.2392 0.0400 0.5012 0.9837 1.0013
## veg_height-Sylvilagus_floridanus 0.1728 0.2514 -0.3378 0.1761 0.6582 1.0074
## veg_height-Meleagris_gallopavo -0.0933 0.4329 -1.0389 -0.0866 0.7345 1.0301
## veg_height-Sciurus_carolinensis 0.1722 0.2227 -0.2494 0.1666 0.6169 1.0057
## week-Canis_latrans 0.4501 0.2457 -0.0132 0.4410 0.9498 1.0022
## week-Procyon_lotor 0.1574 0.1974 -0.2290 0.1570 0.5486 1.0020
## week-Dasypus_novemcinctus 0.0735 0.2135 -0.3478 0.0715 0.4918 1.0013
## week-Lynx_rufus 0.2658 0.2940 -0.3177 0.2552 0.8599 1.0044
## week-Didelphis_virginiana 0.0558 0.3106 -0.5949 0.0638 0.6354 1.0049
## week-Sylvilagus_floridanus 0.0437 0.2928 -0.5539 0.0526 0.6104 1.0031
## week-Meleagris_gallopavo -0.0902 0.3399 -0.8179 -0.0672 0.4993 1.0040
## week-Sciurus_carolinensis 0.5423 0.3287 -0.0303 0.5130 1.2597 1.0003
## I(week^2)-Canis_latrans -0.1951 0.1028 -0.4041 -0.1934 0.0010 1.0002
## I(week^2)-Procyon_lotor -0.1078 0.0870 -0.2782 -0.1063 0.0630 1.0019
## I(week^2)-Dasypus_novemcinctus -0.1594 0.1021 -0.3651 -0.1583 0.0381 1.0069
## I(week^2)-Lynx_rufus -0.2042 0.1432 -0.5010 -0.1988 0.0620 1.0236
## I(week^2)-Didelphis_virginiana -0.3660 0.2033 -0.8310 -0.3441 -0.0269 1.0239
## I(week^2)-Sylvilagus_floridanus -0.1660 0.1507 -0.4774 -0.1602 0.1217 1.0023
## I(week^2)-Meleagris_gallopavo -0.3754 0.2378 -0.9496 -0.3444 -0.0059 1.0174
## I(week^2)-Sciurus_carolinensis -0.1974 0.1398 -0.4950 -0.1904 0.0562 1.0009
## ESS
## (Intercept)-Canis_latrans 1332
## (Intercept)-Procyon_lotor 1798
## (Intercept)-Dasypus_novemcinctus 1551
## (Intercept)-Lynx_rufus 565
## (Intercept)-Didelphis_virginiana 762
## (Intercept)-Sylvilagus_floridanus 1084
## (Intercept)-Meleagris_gallopavo 346
## (Intercept)-Sciurus_carolinensis 566
## shrub_cover-Canis_latrans 765
## shrub_cover-Procyon_lotor 1561
## shrub_cover-Dasypus_novemcinctus 867
## shrub_cover-Lynx_rufus 532
## shrub_cover-Didelphis_virginiana 688
## shrub_cover-Sylvilagus_floridanus 559
## shrub_cover-Meleagris_gallopavo 406
## shrub_cover-Sciurus_carolinensis 433
## veg_height-Canis_latrans 824
## veg_height-Procyon_lotor 1903
## veg_height-Dasypus_novemcinctus 2365
## veg_height-Lynx_rufus 722
## veg_height-Didelphis_virginiana 1317
## veg_height-Sylvilagus_floridanus 785
## veg_height-Meleagris_gallopavo 317
## veg_height-Sciurus_carolinensis 1196
## week-Canis_latrans 1661
## week-Procyon_lotor 2428
## week-Dasypus_novemcinctus 2587
## week-Lynx_rufus 1273
## week-Didelphis_virginiana 1429
## week-Sylvilagus_floridanus 1242
## week-Meleagris_gallopavo 874
## week-Sciurus_carolinensis 1466
## I(week^2)-Canis_latrans 1802
## I(week^2)-Procyon_lotor 2293
## I(week^2)-Dasypus_novemcinctus 1888
## I(week^2)-Lynx_rufus 1031
## I(week^2)-Didelphis_virginiana 635
## I(week^2)-Sylvilagus_floridanus 1105
## I(week^2)-Meleagris_gallopavo 313
## I(week^2)-Sciurus_carolinensis 1567
waicOcc(ms_full_full, by.sp = FALSE)
## elpd pD WAIC
## -964.88079 98.47668 2126.71493
waicOcc(ms_null_null, by.sp = FALSE)
## elpd pD WAIC
## -1066.4908 27.5828 2188.1471
waicOcc(ms_cover_forage, by.sp = FALSE)
## elpd pD WAIC
## -1015.79024 76.55811 2184.69669
waicOcc(ms_cover_move, by.sp = FALSE)
## elpd pD WAIC
## -1005.71644 85.59243 2182.61774
waicOcc(ms_cover_canopy, by.sp = FALSE)
## elpd pD WAIC
## -1000.39206 73.74044 2148.26501
waicOcc(ms_weekQ_cogonQ, by.sp = FALSE)
## elpd pD WAIC
## -1038.0303 58.0199 2192.1004
waicOcc(ms_fullQ_cover, by.sp = FALSE)
## elpd pD WAIC
## -997.0901 101.3120 2196.8041
waicOcc(ms_fullQ_forage, by.sp = FALSE)
## elpd pD WAIC
## -1005.98414 89.02806 2190.02440
waicOcc(ms_fullQ_fullQ, by.sp = FALSE)
## elpd pD WAIC
## -955.300 106.455 2123.510
This test explains how well the model fits that data at the community and species level. I believe 0.5 is the target p-value, though how far from this number is considered adequate, I do not know yet. I believe this is a good place to check when thinking about which species we include in the model (currently set at mammals with > 2 occurences).
ppc.ms_fullQ_fullQ <- ppcOcc(ms_fullQ_fullQ, fit.stat = "freeman-tukey", group = 1)
## Currently on species 1 out of 8
## Currently on species 2 out of 8
## Currently on species 3 out of 8
## Currently on species 4 out of 8
## Currently on species 5 out of 8
## Currently on species 6 out of 8
## Currently on species 7 out of 8
## Currently on species 8 out of 8
summary(ppc.ms_fullQ_fullQ)
##
## Call:
## ppcOcc(object = ms_fullQ_fullQ, fit.stat = "freeman-tukey", group = 1)
##
## Samples per Chain: 5000
## Burn-in: 3000
## Thinning Rate: 2
## Number of Chains: 4
## Total Posterior Samples: 4000
##
## ----------------------------------------
## Community Level
## ----------------------------------------
## Bayesian p-value: 0.3468
##
## ----------------------------------------
## Species Level
## ----------------------------------------
## Canis_latrans Bayesian p-value: 0.6495
## Procyon_lotor Bayesian p-value: 0.082
## Dasypus_novemcinctus Bayesian p-value: 0
## Lynx_rufus Bayesian p-value: 0.3498
## Didelphis_virginiana Bayesian p-value: 0.3982
## Sylvilagus_floridanus Bayesian p-value: 0.3975
## Meleagris_gallopavo Bayesian p-value: 0.6018
## Sciurus_carolinensis Bayesian p-value: 0.2952
## Fit statistic: freeman-tukey
summary(ms_fullQ_fullQ) # Summary of parameter estimates
##
## Call:
## msPGOcc(occ.formula = occ.full.quad, det.formula = det.full.quad,
## data = data_list, n.samples = 5000, n.report = 500, n.burn = 3000,
## n.thin = 2, n.chains = 4)
##
## Samples per Chain: 5000
## Burn-in: 3000
## Thinning Rate: 2
## Number of Chains: 4
## Total Posterior Samples: 4000
## Run Time (min): 1.0865
##
## ----------------------------------------
## Community Level
## ----------------------------------------
## Occurrence Means (logit scale):
## Mean SD 2.5% 50% 97.5% Rhat ESS
## (Intercept) -1.8388 0.7039 -3.1840 -1.8605 -0.4530 1.0188 500
## Cogon_Patch_Size 0.1097 0.7146 -1.2957 0.1074 1.5175 1.0287 551
## Veg_shannon_index 0.9644 0.4977 0.0036 0.9443 2.0175 1.0221 315
## total_shrub_cover -1.1179 0.6624 -2.5421 -1.0822 0.0835 1.0292 562
## Avg_Cogongrass_Cover 0.0222 1.0082 -2.0320 0.0630 1.9060 1.0566 211
## Tree_Density -2.2349 0.9728 -4.0900 -2.2625 -0.2417 1.0125 253
## Avg_Canopy_Cover 1.8674 0.8003 0.3528 1.8306 3.6120 1.0065 746
## I(Avg_Cogongrass_Cover^2) 1.4121 0.6728 0.0686 1.4083 2.7513 1.0209 403
## avg_veg_height -0.0632 0.5771 -1.2023 -0.0622 1.0266 1.0214 289
##
## Occurrence Variances (logit scale):
## Mean SD 2.5% 50% 97.5% Rhat ESS
## (Intercept) 1.8980 3.6816 0.0681 0.8919 9.6473 1.0501 647
## Cogon_Patch_Size 2.7732 5.0636 0.0915 1.3619 13.8502 1.0760 656
## Veg_shannon_index 0.7404 1.1263 0.0481 0.3821 3.7679 1.0306 674
## total_shrub_cover 2.5130 3.8935 0.1026 1.4186 11.9953 1.1475 375
## Avg_Cogongrass_Cover 1.3452 2.6643 0.0464 0.5367 7.7310 1.0122 689
## Tree_Density 3.8679 7.6623 0.0710 1.4453 23.7704 1.0182 221
## Avg_Canopy_Cover 4.5569 7.2386 0.2118 2.4256 21.4766 1.0274 362
## I(Avg_Cogongrass_Cover^2) 2.5707 5.8501 0.0754 1.1800 13.1664 1.3653 265
## avg_veg_height 0.8130 1.6438 0.0494 0.3536 4.1707 1.0435 656
##
## Occurrence Random Effect Variances (logit scale):
## Mean SD 2.5% 50% 97.5% Rhat ESS
## Auth 1.682 2.3209 0.0554 0.8193 8.2776 1.0567 83
##
## Detection Means (logit scale):
## Mean SD 2.5% 50% 97.5% Rhat ESS
## (Intercept) -2.6221 0.2947 -3.1963 -2.6250 -2.0351 1.0039 2771
## shrub_cover 0.4348 0.3109 -0.1693 0.4343 1.0594 1.0035 1671
## veg_height 0.1317 0.2040 -0.2789 0.1353 0.5216 1.0013 1201
## week 0.1844 0.2002 -0.2163 0.1855 0.5788 1.0025 1617
## I(week^2) -0.2196 0.1206 -0.4760 -0.2152 0.0086 1.0115 1460
##
## Detection Variances (logit scale):
## Mean SD 2.5% 50% 97.5% Rhat ESS
## (Intercept) 0.6397 0.5543 0.1449 0.4879 2.1182 1.0082 1580
## shrub_cover 0.6965 0.6673 0.1312 0.5152 2.2857 1.0069 1183
## veg_height 0.2593 0.2499 0.0587 0.1935 0.8639 1.0132 1673
## week 0.1964 0.2288 0.0334 0.1367 0.7116 1.0038 1302
## I(week^2) 0.0824 0.0913 0.0192 0.0594 0.2802 1.0390 956
##
## ----------------------------------------
## Species Level
## ----------------------------------------
## Occurrence (logit scale):
## Mean SD 2.5% 50%
## (Intercept)-Canis_latrans -1.4612 0.9647 -3.3065 -1.4979
## (Intercept)-Procyon_lotor -1.1199 0.9781 -2.9379 -1.1539
## (Intercept)-Dasypus_novemcinctus -2.2087 0.9282 -4.1465 -2.1435
## (Intercept)-Lynx_rufus -1.4972 1.2119 -3.6189 -1.5991
## (Intercept)-Didelphis_virginiana -2.7444 1.1605 -5.5359 -2.5854
## (Intercept)-Sylvilagus_floridanus -1.9893 1.0303 -4.2285 -1.9389
## (Intercept)-Meleagris_gallopavo -1.8181 1.1133 -3.8852 -1.8504
## (Intercept)-Sciurus_carolinensis -2.9478 1.2533 -5.9004 -2.7642
## Cogon_Patch_Size-Canis_latrans 1.3757 1.2784 -0.4889 1.1466
## Cogon_Patch_Size-Procyon_lotor -0.4773 0.8284 -2.2359 -0.4172
## Cogon_Patch_Size-Dasypus_novemcinctus 0.1317 0.8402 -1.4307 0.1084
## Cogon_Patch_Size-Lynx_rufus -0.0556 1.3817 -2.7740 -0.0997
## Cogon_Patch_Size-Didelphis_virginiana 1.3666 1.0644 -0.3346 1.2328
## Cogon_Patch_Size-Sylvilagus_floridanus -0.9918 1.4255 -4.5041 -0.7741
## Cogon_Patch_Size-Meleagris_gallopavo 0.3573 1.2836 -1.7487 0.2207
## Cogon_Patch_Size-Sciurus_carolinensis -0.7006 1.1886 -3.4262 -0.5378
## Veg_shannon_index-Canis_latrans 1.3162 0.7290 0.0680 1.2510
## Veg_shannon_index-Procyon_lotor 1.1873 0.6328 0.0716 1.1375
## Veg_shannon_index-Dasypus_novemcinctus 0.6164 0.6101 -0.5866 0.6286
## Veg_shannon_index-Lynx_rufus 0.9664 0.8642 -0.6537 0.9252
## Veg_shannon_index-Didelphis_virginiana 1.1598 0.7318 -0.1059 1.1042
## Veg_shannon_index-Sylvilagus_floridanus 1.0592 0.7586 -0.2864 1.0121
## Veg_shannon_index-Meleagris_gallopavo 1.2742 0.8309 -0.1107 1.1932
## Veg_shannon_index-Sciurus_carolinensis 0.3958 0.8080 -1.3944 0.4636
## total_shrub_cover-Canis_latrans 0.1819 0.8803 -1.3615 0.0971
## total_shrub_cover-Procyon_lotor -1.5190 0.7477 -3.1525 -1.4495
## total_shrub_cover-Dasypus_novemcinctus -0.5127 0.8741 -2.4577 -0.4475
## total_shrub_cover-Lynx_rufus -1.9368 1.3047 -4.9284 -1.7492
## total_shrub_cover-Didelphis_virginiana -1.3552 1.0591 -3.7713 -1.2379
## total_shrub_cover-Sylvilagus_floridanus -1.1617 1.1701 -3.8086 -1.0503
## total_shrub_cover-Meleagris_gallopavo -2.5838 1.5406 -6.1529 -2.3489
## total_shrub_cover-Sciurus_carolinensis -1.1082 1.2118 -3.9932 -0.9704
## Avg_Cogongrass_Cover-Canis_latrans 0.1375 1.2267 -2.2852 0.1665
## Avg_Cogongrass_Cover-Procyon_lotor -0.0710 1.2094 -2.5535 -0.0326
## Avg_Cogongrass_Cover-Dasypus_novemcinctus 0.6007 1.3551 -1.8670 0.5481
## Avg_Cogongrass_Cover-Lynx_rufus 0.0302 1.3146 -2.5422 0.0461
## Avg_Cogongrass_Cover-Didelphis_virginiana 0.1999 1.3260 -2.3778 0.2131
## Avg_Cogongrass_Cover-Sylvilagus_floridanus -0.6011 1.3691 -3.5766 -0.5250
## Avg_Cogongrass_Cover-Meleagris_gallopavo -0.2749 1.4112 -3.3157 -0.1839
## Avg_Cogongrass_Cover-Sciurus_carolinensis 0.1251 1.2545 -2.3162 0.1349
## Tree_Density-Canis_latrans -3.2445 1.5831 -6.9676 -3.0045
## Tree_Density-Procyon_lotor -2.3402 1.1145 -4.6827 -2.3036
## Tree_Density-Dasypus_novemcinctus -4.0305 2.0135 -9.2148 -3.5829
## Tree_Density-Lynx_rufus -1.0467 1.7873 -3.9773 -1.2378
## Tree_Density-Didelphis_virginiana -2.3088 1.2941 -4.9392 -2.2467
## Tree_Density-Sylvilagus_floridanus -2.7936 1.4987 -5.9693 -2.6710
## Tree_Density-Meleagris_gallopavo -2.3564 1.5141 -5.4048 -2.3705
## Tree_Density-Sciurus_carolinensis -2.4134 1.5391 -5.7836 -2.3740
## Avg_Canopy_Cover-Canis_latrans 0.0965 0.7006 -1.3626 0.1022
## Avg_Canopy_Cover-Procyon_lotor 1.6306 0.8442 0.1418 1.5749
## Avg_Canopy_Cover-Dasypus_novemcinctus 2.2923 0.9627 0.7974 2.1772
## Avg_Canopy_Cover-Lynx_rufus 1.0312 1.3821 -1.5235 0.9518
## Avg_Canopy_Cover-Didelphis_virginiana 3.1806 1.3995 1.1679 2.9638
## Avg_Canopy_Cover-Sylvilagus_floridanus 4.0152 2.0001 1.2295 3.6383
## Avg_Canopy_Cover-Meleagris_gallopavo 2.4539 1.3579 0.4919 2.1969
## Avg_Canopy_Cover-Sciurus_carolinensis 3.1201 1.6529 0.9502 2.7602
## I(Avg_Cogongrass_Cover^2)-Canis_latrans 2.3977 1.2869 0.6480 2.1717
## I(Avg_Cogongrass_Cover^2)-Procyon_lotor 2.4398 1.3611 0.6628 2.2036
## I(Avg_Cogongrass_Cover^2)-Dasypus_novemcinctus 1.3992 0.7716 0.0047 1.3382
## I(Avg_Cogongrass_Cover^2)-Lynx_rufus 2.6681 1.3445 0.7840 2.4084
## I(Avg_Cogongrass_Cover^2)-Didelphis_virginiana 0.7956 0.7837 -0.7308 0.7968
## I(Avg_Cogongrass_Cover^2)-Sylvilagus_floridanus 1.0898 0.9116 -0.5264 1.0239
## I(Avg_Cogongrass_Cover^2)-Meleagris_gallopavo 0.2262 1.5128 -3.1665 0.3654
## I(Avg_Cogongrass_Cover^2)-Sciurus_carolinensis 1.4706 0.8375 0.0255 1.3858
## avg_veg_height-Canis_latrans -0.2427 0.6812 -1.6255 -0.2161
## avg_veg_height-Procyon_lotor 0.0670 0.6971 -1.3077 0.0552
## avg_veg_height-Dasypus_novemcinctus 0.3288 0.7008 -0.9392 0.2887
## avg_veg_height-Lynx_rufus -0.4832 1.0406 -2.9428 -0.3618
## avg_veg_height-Didelphis_virginiana -0.2651 0.7989 -1.9855 -0.2179
## avg_veg_height-Sylvilagus_floridanus -0.1966 0.7925 -1.8544 -0.1730
## avg_veg_height-Meleagris_gallopavo -0.1072 1.0131 -2.2708 -0.0751
## avg_veg_height-Sciurus_carolinensis 0.4069 0.8542 -1.0162 0.3177
## 97.5% Rhat ESS
## (Intercept)-Canis_latrans 0.5537 1.0200 424
## (Intercept)-Procyon_lotor 0.8397 1.0268 371
## (Intercept)-Dasypus_novemcinctus -0.6231 1.0427 419
## (Intercept)-Lynx_rufus 1.3552 1.0217 352
## (Intercept)-Didelphis_virginiana -0.9063 1.0120 485
## (Intercept)-Sylvilagus_floridanus -0.0874 1.0232 605
## (Intercept)-Meleagris_gallopavo 0.5151 1.0308 481
## (Intercept)-Sciurus_carolinensis -0.9603 1.0137 402
## Cogon_Patch_Size-Canis_latrans 4.5853 1.0617 541
## Cogon_Patch_Size-Procyon_lotor 0.9717 1.0351 358
## Cogon_Patch_Size-Dasypus_novemcinctus 1.8799 1.0185 795
## Cogon_Patch_Size-Lynx_rufus 2.8100 1.0372 391
## Cogon_Patch_Size-Didelphis_virginiana 3.8112 1.0355 413
## Cogon_Patch_Size-Sylvilagus_floridanus 1.1627 1.0360 439
## Cogon_Patch_Size-Meleagris_gallopavo 3.5373 1.0310 505
## Cogon_Patch_Size-Sciurus_carolinensis 1.2252 1.0237 530
## Veg_shannon_index-Canis_latrans 2.9443 1.0110 607
## Veg_shannon_index-Procyon_lotor 2.5949 1.0101 393
## Veg_shannon_index-Dasypus_novemcinctus 1.8144 1.0083 1009
## Veg_shannon_index-Lynx_rufus 2.7660 1.0214 497
## Veg_shannon_index-Didelphis_virginiana 2.7652 1.0235 633
## Veg_shannon_index-Sylvilagus_floridanus 2.6023 1.0233 432
## Veg_shannon_index-Meleagris_gallopavo 3.1278 1.0222 573
## Veg_shannon_index-Sciurus_carolinensis 1.8402 1.0102 665
## total_shrub_cover-Canis_latrans 2.2742 1.0363 495
## total_shrub_cover-Procyon_lotor -0.2054 1.0034 678
## total_shrub_cover-Dasypus_novemcinctus 0.9854 1.0110 635
## total_shrub_cover-Lynx_rufus 0.1844 1.0587 334
## total_shrub_cover-Didelphis_virginiana 0.3482 1.0105 656
## total_shrub_cover-Sylvilagus_floridanus 0.8228 1.0780 427
## total_shrub_cover-Meleagris_gallopavo -0.2961 1.0796 281
## total_shrub_cover-Sciurus_carolinensis 0.8883 1.0432 357
## Avg_Cogongrass_Cover-Canis_latrans 2.5321 1.0294 295
## Avg_Cogongrass_Cover-Procyon_lotor 2.2334 1.0426 315
## Avg_Cogongrass_Cover-Dasypus_novemcinctus 3.6595 1.0602 255
## Avg_Cogongrass_Cover-Lynx_rufus 2.6212 1.0159 384
## Avg_Cogongrass_Cover-Didelphis_virginiana 2.9102 1.0568 321
## Avg_Cogongrass_Cover-Sylvilagus_floridanus 1.7769 1.0422 296
## Avg_Cogongrass_Cover-Meleagris_gallopavo 2.2053 1.0324 337
## Avg_Cogongrass_Cover-Sciurus_carolinensis 2.6704 1.0391 305
## Tree_Density-Canis_latrans -0.8898 1.0164 262
## Tree_Density-Procyon_lotor -0.3249 1.0263 371
## Tree_Density-Dasypus_novemcinctus -1.3643 1.0119 214
## Tree_Density-Lynx_rufus 3.1789 1.0137 198
## Tree_Density-Didelphis_virginiana 0.1324 1.0024 605
## Tree_Density-Sylvilagus_floridanus -0.2476 1.0085 338
## Tree_Density-Meleagris_gallopavo 0.4739 1.0299 375
## Tree_Density-Sciurus_carolinensis 0.5703 1.0222 352
## Avg_Canopy_Cover-Canis_latrans 1.4526 1.0035 708
## Avg_Canopy_Cover-Procyon_lotor 3.4995 1.0089 330
## Avg_Canopy_Cover-Dasypus_novemcinctus 4.5188 1.0144 382
## Avg_Canopy_Cover-Lynx_rufus 3.9508 1.0311 360
## Avg_Canopy_Cover-Didelphis_virginiana 6.5335 1.0125 325
## Avg_Canopy_Cover-Sylvilagus_floridanus 8.8186 1.0246 228
## Avg_Canopy_Cover-Meleagris_gallopavo 5.8931 1.0177 260
## Avg_Canopy_Cover-Sciurus_carolinensis 7.4120 1.0391 289
## I(Avg_Cogongrass_Cover^2)-Canis_latrans 5.3447 1.1012 239
## I(Avg_Cogongrass_Cover^2)-Procyon_lotor 5.6796 1.1770 228
## I(Avg_Cogongrass_Cover^2)-Dasypus_novemcinctus 3.0459 1.0153 721
## I(Avg_Cogongrass_Cover^2)-Lynx_rufus 6.0419 1.0388 287
## I(Avg_Cogongrass_Cover^2)-Didelphis_virginiana 2.3742 1.0449 327
## I(Avg_Cogongrass_Cover^2)-Sylvilagus_floridanus 3.1155 1.0559 395
## I(Avg_Cogongrass_Cover^2)-Meleagris_gallopavo 2.8144 1.0749 156
## I(Avg_Cogongrass_Cover^2)-Sciurus_carolinensis 3.3243 1.0084 689
## avg_veg_height-Canis_latrans 1.0697 1.0103 525
## avg_veg_height-Procyon_lotor 1.4885 1.0194 521
## avg_veg_height-Dasypus_novemcinctus 1.8386 1.0130 586
## avg_veg_height-Lynx_rufus 1.2262 1.0366 306
## avg_veg_height-Didelphis_virginiana 1.2609 1.0122 553
## avg_veg_height-Sylvilagus_floridanus 1.3267 1.0175 471
## avg_veg_height-Meleagris_gallopavo 1.7760 1.0175 428
## avg_veg_height-Sciurus_carolinensis 2.3835 1.0037 459
##
## Detection (logit scale):
## Mean SD 2.5% 50% 97.5% Rhat
## (Intercept)-Canis_latrans -2.5674 0.1902 -2.9593 -2.5650 -2.2046 1.0058
## (Intercept)-Procyon_lotor -2.2224 0.1610 -2.5405 -2.2200 -1.9132 1.0097
## (Intercept)-Dasypus_novemcinctus -1.7109 0.1873 -2.0857 -1.7060 -1.3577 1.0055
## (Intercept)-Lynx_rufus -3.4535 0.3320 -4.1269 -3.4495 -2.8369 1.0092
## (Intercept)-Didelphis_virginiana -2.4910 0.2922 -3.0670 -2.4931 -1.9078 1.0044
## (Intercept)-Sylvilagus_floridanus -3.0651 0.2749 -3.6484 -3.0535 -2.5686 1.0112
## (Intercept)-Meleagris_gallopavo -3.4161 0.4751 -4.3549 -3.4278 -2.4904 1.0327
## (Intercept)-Sciurus_carolinensis -2.6820 0.3352 -3.3358 -2.6759 -2.0412 1.0027
## shrub_cover-Canis_latrans -0.2897 0.2367 -0.7712 -0.2876 0.1699 1.0021
## shrub_cover-Procyon_lotor 0.2931 0.1624 -0.0362 0.2933 0.6039 0.9998
## shrub_cover-Dasypus_novemcinctus 1.0294 0.3185 0.3902 1.0381 1.6375 1.0041
## shrub_cover-Lynx_rufus 0.0770 0.3568 -0.6265 0.0807 0.7496 1.0258
## shrub_cover-Didelphis_virginiana 1.1253 0.3679 0.4348 1.1155 1.8783 1.0123
## shrub_cover-Sylvilagus_floridanus 0.5914 0.3945 -0.1793 0.5892 1.3560 1.0266
## shrub_cover-Meleagris_gallopavo -0.3542 0.4470 -1.2399 -0.3535 0.5068 1.0325
## shrub_cover-Sciurus_carolinensis 1.1132 0.4195 0.2694 1.1141 1.9208 1.0024
## veg_height-Canis_latrans -0.5496 0.1869 -0.9158 -0.5471 -0.1886 1.0029
## veg_height-Procyon_lotor 0.3734 0.1214 0.1410 0.3726 0.6133 1.0040
## veg_height-Dasypus_novemcinctus 0.2940 0.1373 0.0362 0.2896 0.5661 1.0017
## veg_height-Lynx_rufus 0.1681 0.2422 -0.3144 0.1770 0.6245 1.0142
## veg_height-Didelphis_virginiana 0.5068 0.2392 0.0400 0.5012 0.9837 1.0013
## veg_height-Sylvilagus_floridanus 0.1728 0.2514 -0.3378 0.1761 0.6582 1.0074
## veg_height-Meleagris_gallopavo -0.0933 0.4329 -1.0389 -0.0866 0.7345 1.0301
## veg_height-Sciurus_carolinensis 0.1722 0.2227 -0.2494 0.1666 0.6169 1.0057
## week-Canis_latrans 0.4501 0.2457 -0.0132 0.4410 0.9498 1.0022
## week-Procyon_lotor 0.1574 0.1974 -0.2290 0.1570 0.5486 1.0020
## week-Dasypus_novemcinctus 0.0735 0.2135 -0.3478 0.0715 0.4918 1.0013
## week-Lynx_rufus 0.2658 0.2940 -0.3177 0.2552 0.8599 1.0044
## week-Didelphis_virginiana 0.0558 0.3106 -0.5949 0.0638 0.6354 1.0049
## week-Sylvilagus_floridanus 0.0437 0.2928 -0.5539 0.0526 0.6104 1.0031
## week-Meleagris_gallopavo -0.0902 0.3399 -0.8179 -0.0672 0.4993 1.0040
## week-Sciurus_carolinensis 0.5423 0.3287 -0.0303 0.5130 1.2597 1.0003
## I(week^2)-Canis_latrans -0.1951 0.1028 -0.4041 -0.1934 0.0010 1.0002
## I(week^2)-Procyon_lotor -0.1078 0.0870 -0.2782 -0.1063 0.0630 1.0019
## I(week^2)-Dasypus_novemcinctus -0.1594 0.1021 -0.3651 -0.1583 0.0381 1.0069
## I(week^2)-Lynx_rufus -0.2042 0.1432 -0.5010 -0.1988 0.0620 1.0236
## I(week^2)-Didelphis_virginiana -0.3660 0.2033 -0.8310 -0.3441 -0.0269 1.0239
## I(week^2)-Sylvilagus_floridanus -0.1660 0.1507 -0.4774 -0.1602 0.1217 1.0023
## I(week^2)-Meleagris_gallopavo -0.3754 0.2378 -0.9496 -0.3444 -0.0059 1.0174
## I(week^2)-Sciurus_carolinensis -0.1974 0.1398 -0.4950 -0.1904 0.0562 1.0009
## ESS
## (Intercept)-Canis_latrans 1332
## (Intercept)-Procyon_lotor 1798
## (Intercept)-Dasypus_novemcinctus 1551
## (Intercept)-Lynx_rufus 565
## (Intercept)-Didelphis_virginiana 762
## (Intercept)-Sylvilagus_floridanus 1084
## (Intercept)-Meleagris_gallopavo 346
## (Intercept)-Sciurus_carolinensis 566
## shrub_cover-Canis_latrans 765
## shrub_cover-Procyon_lotor 1561
## shrub_cover-Dasypus_novemcinctus 867
## shrub_cover-Lynx_rufus 532
## shrub_cover-Didelphis_virginiana 688
## shrub_cover-Sylvilagus_floridanus 559
## shrub_cover-Meleagris_gallopavo 406
## shrub_cover-Sciurus_carolinensis 433
## veg_height-Canis_latrans 824
## veg_height-Procyon_lotor 1903
## veg_height-Dasypus_novemcinctus 2365
## veg_height-Lynx_rufus 722
## veg_height-Didelphis_virginiana 1317
## veg_height-Sylvilagus_floridanus 785
## veg_height-Meleagris_gallopavo 317
## veg_height-Sciurus_carolinensis 1196
## week-Canis_latrans 1661
## week-Procyon_lotor 2428
## week-Dasypus_novemcinctus 2587
## week-Lynx_rufus 1273
## week-Didelphis_virginiana 1429
## week-Sylvilagus_floridanus 1242
## week-Meleagris_gallopavo 874
## week-Sciurus_carolinensis 1466
## I(week^2)-Canis_latrans 1802
## I(week^2)-Procyon_lotor 2293
## I(week^2)-Dasypus_novemcinctus 1888
## I(week^2)-Lynx_rufus 1031
## I(week^2)-Didelphis_virginiana 635
## I(week^2)-Sylvilagus_floridanus 1105
## I(week^2)-Meleagris_gallopavo 313
## I(week^2)-Sciurus_carolinensis 1567
names(ms_fullQ_fullQ)
## [1] "rhat" "beta.comm.samples" "alpha.comm.samples"
## [4] "tau.sq.beta.samples" "tau.sq.alpha.samples" "beta.samples"
## [7] "alpha.samples" "z.samples" "psi.samples"
## [10] "like.samples" "sigma.sq.psi.samples" "beta.star.samples"
## [13] "re.level.names" "ESS" "X"
## [16] "X.p" "X.p.re" "X.re"
## [19] "y" "call" "n.samples"
## [22] "x.names" "sp.names" "x.p.names"
## [25] "n.post" "n.thin" "n.burn"
## [28] "n.chains" "pRE" "psiRE"
## [31] "run.time"
str(ms_fullQ_fullQ$beta.samples)
## 'mcmc' num [1:4000, 1:72] -0.195 -0.47 -0.722 -2.076 -0.625 ...
## - attr(*, "mcpar")= num [1:3] 1 4000 1
## - attr(*, "dimnames")=List of 2
## ..$ : NULL
## ..$ : chr [1:72] "(Intercept)-Canis_latrans" "(Intercept)-Procyon_lotor" "(Intercept)-Dasypus_novemcinctus" "(Intercept)-Lynx_rufus" ...
mean(ms_fullQ_fullQ$beta.samples[, 5] > 0) # effect of ? on occupancy
## [1] 0.001
MCMCplot(ms_fullQ_fullQ$beta.samples, ref_ovl = TRUE, ci = c(50, 95)) # Occupancy
MCMCplot(ms_fullQ_fullQ$alpha.samples, ref_ovl = TRUE, ci = c(50, 95)) # Detection
# 1. Create a sequence of unscaled cogongrass cover values
cogon.pred.vals <- seq(min(data_list$occ.covs$Avg_Cogongrass_Cover),
max(data_list$occ.covs$Avg_Cogongrass_Cover),
length.out = 100)
# 2. Scale using the same transformation used in the model
cogon.mean <- mean(data_list$occ.covs$Avg_Cogongrass_Cover)
cogon.sd <- sd(data_list$occ.covs$Avg_Cogongrass_Cover)
cogon.pred.scale <- (cogon.pred.vals - cogon.mean) / cogon.sd
# 3. Generate the quadratic term (scaled^2)
cogon.pred.scale2 <- cogon.pred.scale^2
# 4. Prediction matrix: set all other covariates to their means (recommended)
# Replace 0 with mean(...) if you want predictions at mean conditions
pred.df <- as.matrix(data.frame(
intercept = 1,
Avg_Cogongrass_Cover = cogon.pred.scale,
I.Avg_Cogongrass_Cover.2. = cogon.pred.scale2,
Cogon_Patch_Size = 0,
Veg_shannon_index = 0,
total_shrub_cover = 0,
Tree_Density = 0,
Avg_Canopy_Cover = 0,
avg_veg_height = 0,
Auth = 0
))
# 5. Predict occupancy from the model
out.pred <- predict(ms_fullQ_fullQ, pred.df)
# 6. Convert posterior samples to quantiles
psi.0.quants <- apply(out.pred$psi.0.samples, 3,
function(x) quantile(x, prob = c(0.025, 0.5, 0.975)))
# 7. Format for plotting
psi.plot.dat <- data.frame(
psi.med = psi.0.quants[2, ],
psi.low = psi.0.quants[1, ],
psi.high = psi.0.quants[3, ],
Avg_Cogongrass_Cover = cogon.pred.vals
)
# 8. Plot
ggplot(psi.plot.dat, aes(x = Avg_Cogongrass_Cover, y = psi.med)) +
geom_ribbon(aes(ymin = psi.low, ymax = psi.high), fill = "grey70") +
geom_line(size = 1.1) +
theme_bw() +
labs(x = "Average Cogongrass Cover (%)", y = "Predicted Occupancy") +
scale_y_continuous(limits = c(0,1))
## Warning: Using `size` aesthetic for lines was deprecated in ggplot2 3.4.0.
## ℹ Please use `linewidth` instead.
## This warning is displayed once every 8 hours.
## Call `lifecycle::last_lifecycle_warnings()` to see where this warning was
## generated.
summary(ms_fullQ_fullQ) # Summary of parameter estimates
##
## Call:
## msPGOcc(occ.formula = occ.full.quad, det.formula = det.full.quad,
## data = data_list, n.samples = 5000, n.report = 500, n.burn = 3000,
## n.thin = 2, n.chains = 4)
##
## Samples per Chain: 5000
## Burn-in: 3000
## Thinning Rate: 2
## Number of Chains: 4
## Total Posterior Samples: 4000
## Run Time (min): 1.0865
##
## ----------------------------------------
## Community Level
## ----------------------------------------
## Occurrence Means (logit scale):
## Mean SD 2.5% 50% 97.5% Rhat ESS
## (Intercept) -1.8388 0.7039 -3.1840 -1.8605 -0.4530 1.0188 500
## Cogon_Patch_Size 0.1097 0.7146 -1.2957 0.1074 1.5175 1.0287 551
## Veg_shannon_index 0.9644 0.4977 0.0036 0.9443 2.0175 1.0221 315
## total_shrub_cover -1.1179 0.6624 -2.5421 -1.0822 0.0835 1.0292 562
## Avg_Cogongrass_Cover 0.0222 1.0082 -2.0320 0.0630 1.9060 1.0566 211
## Tree_Density -2.2349 0.9728 -4.0900 -2.2625 -0.2417 1.0125 253
## Avg_Canopy_Cover 1.8674 0.8003 0.3528 1.8306 3.6120 1.0065 746
## I(Avg_Cogongrass_Cover^2) 1.4121 0.6728 0.0686 1.4083 2.7513 1.0209 403
## avg_veg_height -0.0632 0.5771 -1.2023 -0.0622 1.0266 1.0214 289
##
## Occurrence Variances (logit scale):
## Mean SD 2.5% 50% 97.5% Rhat ESS
## (Intercept) 1.8980 3.6816 0.0681 0.8919 9.6473 1.0501 647
## Cogon_Patch_Size 2.7732 5.0636 0.0915 1.3619 13.8502 1.0760 656
## Veg_shannon_index 0.7404 1.1263 0.0481 0.3821 3.7679 1.0306 674
## total_shrub_cover 2.5130 3.8935 0.1026 1.4186 11.9953 1.1475 375
## Avg_Cogongrass_Cover 1.3452 2.6643 0.0464 0.5367 7.7310 1.0122 689
## Tree_Density 3.8679 7.6623 0.0710 1.4453 23.7704 1.0182 221
## Avg_Canopy_Cover 4.5569 7.2386 0.2118 2.4256 21.4766 1.0274 362
## I(Avg_Cogongrass_Cover^2) 2.5707 5.8501 0.0754 1.1800 13.1664 1.3653 265
## avg_veg_height 0.8130 1.6438 0.0494 0.3536 4.1707 1.0435 656
##
## Occurrence Random Effect Variances (logit scale):
## Mean SD 2.5% 50% 97.5% Rhat ESS
## Auth 1.682 2.3209 0.0554 0.8193 8.2776 1.0567 83
##
## Detection Means (logit scale):
## Mean SD 2.5% 50% 97.5% Rhat ESS
## (Intercept) -2.6221 0.2947 -3.1963 -2.6250 -2.0351 1.0039 2771
## shrub_cover 0.4348 0.3109 -0.1693 0.4343 1.0594 1.0035 1671
## veg_height 0.1317 0.2040 -0.2789 0.1353 0.5216 1.0013 1201
## week 0.1844 0.2002 -0.2163 0.1855 0.5788 1.0025 1617
## I(week^2) -0.2196 0.1206 -0.4760 -0.2152 0.0086 1.0115 1460
##
## Detection Variances (logit scale):
## Mean SD 2.5% 50% 97.5% Rhat ESS
## (Intercept) 0.6397 0.5543 0.1449 0.4879 2.1182 1.0082 1580
## shrub_cover 0.6965 0.6673 0.1312 0.5152 2.2857 1.0069 1183
## veg_height 0.2593 0.2499 0.0587 0.1935 0.8639 1.0132 1673
## week 0.1964 0.2288 0.0334 0.1367 0.7116 1.0038 1302
## I(week^2) 0.0824 0.0913 0.0192 0.0594 0.2802 1.0390 956
##
## ----------------------------------------
## Species Level
## ----------------------------------------
## Occurrence (logit scale):
## Mean SD 2.5% 50%
## (Intercept)-Canis_latrans -1.4612 0.9647 -3.3065 -1.4979
## (Intercept)-Procyon_lotor -1.1199 0.9781 -2.9379 -1.1539
## (Intercept)-Dasypus_novemcinctus -2.2087 0.9282 -4.1465 -2.1435
## (Intercept)-Lynx_rufus -1.4972 1.2119 -3.6189 -1.5991
## (Intercept)-Didelphis_virginiana -2.7444 1.1605 -5.5359 -2.5854
## (Intercept)-Sylvilagus_floridanus -1.9893 1.0303 -4.2285 -1.9389
## (Intercept)-Meleagris_gallopavo -1.8181 1.1133 -3.8852 -1.8504
## (Intercept)-Sciurus_carolinensis -2.9478 1.2533 -5.9004 -2.7642
## Cogon_Patch_Size-Canis_latrans 1.3757 1.2784 -0.4889 1.1466
## Cogon_Patch_Size-Procyon_lotor -0.4773 0.8284 -2.2359 -0.4172
## Cogon_Patch_Size-Dasypus_novemcinctus 0.1317 0.8402 -1.4307 0.1084
## Cogon_Patch_Size-Lynx_rufus -0.0556 1.3817 -2.7740 -0.0997
## Cogon_Patch_Size-Didelphis_virginiana 1.3666 1.0644 -0.3346 1.2328
## Cogon_Patch_Size-Sylvilagus_floridanus -0.9918 1.4255 -4.5041 -0.7741
## Cogon_Patch_Size-Meleagris_gallopavo 0.3573 1.2836 -1.7487 0.2207
## Cogon_Patch_Size-Sciurus_carolinensis -0.7006 1.1886 -3.4262 -0.5378
## Veg_shannon_index-Canis_latrans 1.3162 0.7290 0.0680 1.2510
## Veg_shannon_index-Procyon_lotor 1.1873 0.6328 0.0716 1.1375
## Veg_shannon_index-Dasypus_novemcinctus 0.6164 0.6101 -0.5866 0.6286
## Veg_shannon_index-Lynx_rufus 0.9664 0.8642 -0.6537 0.9252
## Veg_shannon_index-Didelphis_virginiana 1.1598 0.7318 -0.1059 1.1042
## Veg_shannon_index-Sylvilagus_floridanus 1.0592 0.7586 -0.2864 1.0121
## Veg_shannon_index-Meleagris_gallopavo 1.2742 0.8309 -0.1107 1.1932
## Veg_shannon_index-Sciurus_carolinensis 0.3958 0.8080 -1.3944 0.4636
## total_shrub_cover-Canis_latrans 0.1819 0.8803 -1.3615 0.0971
## total_shrub_cover-Procyon_lotor -1.5190 0.7477 -3.1525 -1.4495
## total_shrub_cover-Dasypus_novemcinctus -0.5127 0.8741 -2.4577 -0.4475
## total_shrub_cover-Lynx_rufus -1.9368 1.3047 -4.9284 -1.7492
## total_shrub_cover-Didelphis_virginiana -1.3552 1.0591 -3.7713 -1.2379
## total_shrub_cover-Sylvilagus_floridanus -1.1617 1.1701 -3.8086 -1.0503
## total_shrub_cover-Meleagris_gallopavo -2.5838 1.5406 -6.1529 -2.3489
## total_shrub_cover-Sciurus_carolinensis -1.1082 1.2118 -3.9932 -0.9704
## Avg_Cogongrass_Cover-Canis_latrans 0.1375 1.2267 -2.2852 0.1665
## Avg_Cogongrass_Cover-Procyon_lotor -0.0710 1.2094 -2.5535 -0.0326
## Avg_Cogongrass_Cover-Dasypus_novemcinctus 0.6007 1.3551 -1.8670 0.5481
## Avg_Cogongrass_Cover-Lynx_rufus 0.0302 1.3146 -2.5422 0.0461
## Avg_Cogongrass_Cover-Didelphis_virginiana 0.1999 1.3260 -2.3778 0.2131
## Avg_Cogongrass_Cover-Sylvilagus_floridanus -0.6011 1.3691 -3.5766 -0.5250
## Avg_Cogongrass_Cover-Meleagris_gallopavo -0.2749 1.4112 -3.3157 -0.1839
## Avg_Cogongrass_Cover-Sciurus_carolinensis 0.1251 1.2545 -2.3162 0.1349
## Tree_Density-Canis_latrans -3.2445 1.5831 -6.9676 -3.0045
## Tree_Density-Procyon_lotor -2.3402 1.1145 -4.6827 -2.3036
## Tree_Density-Dasypus_novemcinctus -4.0305 2.0135 -9.2148 -3.5829
## Tree_Density-Lynx_rufus -1.0467 1.7873 -3.9773 -1.2378
## Tree_Density-Didelphis_virginiana -2.3088 1.2941 -4.9392 -2.2467
## Tree_Density-Sylvilagus_floridanus -2.7936 1.4987 -5.9693 -2.6710
## Tree_Density-Meleagris_gallopavo -2.3564 1.5141 -5.4048 -2.3705
## Tree_Density-Sciurus_carolinensis -2.4134 1.5391 -5.7836 -2.3740
## Avg_Canopy_Cover-Canis_latrans 0.0965 0.7006 -1.3626 0.1022
## Avg_Canopy_Cover-Procyon_lotor 1.6306 0.8442 0.1418 1.5749
## Avg_Canopy_Cover-Dasypus_novemcinctus 2.2923 0.9627 0.7974 2.1772
## Avg_Canopy_Cover-Lynx_rufus 1.0312 1.3821 -1.5235 0.9518
## Avg_Canopy_Cover-Didelphis_virginiana 3.1806 1.3995 1.1679 2.9638
## Avg_Canopy_Cover-Sylvilagus_floridanus 4.0152 2.0001 1.2295 3.6383
## Avg_Canopy_Cover-Meleagris_gallopavo 2.4539 1.3579 0.4919 2.1969
## Avg_Canopy_Cover-Sciurus_carolinensis 3.1201 1.6529 0.9502 2.7602
## I(Avg_Cogongrass_Cover^2)-Canis_latrans 2.3977 1.2869 0.6480 2.1717
## I(Avg_Cogongrass_Cover^2)-Procyon_lotor 2.4398 1.3611 0.6628 2.2036
## I(Avg_Cogongrass_Cover^2)-Dasypus_novemcinctus 1.3992 0.7716 0.0047 1.3382
## I(Avg_Cogongrass_Cover^2)-Lynx_rufus 2.6681 1.3445 0.7840 2.4084
## I(Avg_Cogongrass_Cover^2)-Didelphis_virginiana 0.7956 0.7837 -0.7308 0.7968
## I(Avg_Cogongrass_Cover^2)-Sylvilagus_floridanus 1.0898 0.9116 -0.5264 1.0239
## I(Avg_Cogongrass_Cover^2)-Meleagris_gallopavo 0.2262 1.5128 -3.1665 0.3654
## I(Avg_Cogongrass_Cover^2)-Sciurus_carolinensis 1.4706 0.8375 0.0255 1.3858
## avg_veg_height-Canis_latrans -0.2427 0.6812 -1.6255 -0.2161
## avg_veg_height-Procyon_lotor 0.0670 0.6971 -1.3077 0.0552
## avg_veg_height-Dasypus_novemcinctus 0.3288 0.7008 -0.9392 0.2887
## avg_veg_height-Lynx_rufus -0.4832 1.0406 -2.9428 -0.3618
## avg_veg_height-Didelphis_virginiana -0.2651 0.7989 -1.9855 -0.2179
## avg_veg_height-Sylvilagus_floridanus -0.1966 0.7925 -1.8544 -0.1730
## avg_veg_height-Meleagris_gallopavo -0.1072 1.0131 -2.2708 -0.0751
## avg_veg_height-Sciurus_carolinensis 0.4069 0.8542 -1.0162 0.3177
## 97.5% Rhat ESS
## (Intercept)-Canis_latrans 0.5537 1.0200 424
## (Intercept)-Procyon_lotor 0.8397 1.0268 371
## (Intercept)-Dasypus_novemcinctus -0.6231 1.0427 419
## (Intercept)-Lynx_rufus 1.3552 1.0217 352
## (Intercept)-Didelphis_virginiana -0.9063 1.0120 485
## (Intercept)-Sylvilagus_floridanus -0.0874 1.0232 605
## (Intercept)-Meleagris_gallopavo 0.5151 1.0308 481
## (Intercept)-Sciurus_carolinensis -0.9603 1.0137 402
## Cogon_Patch_Size-Canis_latrans 4.5853 1.0617 541
## Cogon_Patch_Size-Procyon_lotor 0.9717 1.0351 358
## Cogon_Patch_Size-Dasypus_novemcinctus 1.8799 1.0185 795
## Cogon_Patch_Size-Lynx_rufus 2.8100 1.0372 391
## Cogon_Patch_Size-Didelphis_virginiana 3.8112 1.0355 413
## Cogon_Patch_Size-Sylvilagus_floridanus 1.1627 1.0360 439
## Cogon_Patch_Size-Meleagris_gallopavo 3.5373 1.0310 505
## Cogon_Patch_Size-Sciurus_carolinensis 1.2252 1.0237 530
## Veg_shannon_index-Canis_latrans 2.9443 1.0110 607
## Veg_shannon_index-Procyon_lotor 2.5949 1.0101 393
## Veg_shannon_index-Dasypus_novemcinctus 1.8144 1.0083 1009
## Veg_shannon_index-Lynx_rufus 2.7660 1.0214 497
## Veg_shannon_index-Didelphis_virginiana 2.7652 1.0235 633
## Veg_shannon_index-Sylvilagus_floridanus 2.6023 1.0233 432
## Veg_shannon_index-Meleagris_gallopavo 3.1278 1.0222 573
## Veg_shannon_index-Sciurus_carolinensis 1.8402 1.0102 665
## total_shrub_cover-Canis_latrans 2.2742 1.0363 495
## total_shrub_cover-Procyon_lotor -0.2054 1.0034 678
## total_shrub_cover-Dasypus_novemcinctus 0.9854 1.0110 635
## total_shrub_cover-Lynx_rufus 0.1844 1.0587 334
## total_shrub_cover-Didelphis_virginiana 0.3482 1.0105 656
## total_shrub_cover-Sylvilagus_floridanus 0.8228 1.0780 427
## total_shrub_cover-Meleagris_gallopavo -0.2961 1.0796 281
## total_shrub_cover-Sciurus_carolinensis 0.8883 1.0432 357
## Avg_Cogongrass_Cover-Canis_latrans 2.5321 1.0294 295
## Avg_Cogongrass_Cover-Procyon_lotor 2.2334 1.0426 315
## Avg_Cogongrass_Cover-Dasypus_novemcinctus 3.6595 1.0602 255
## Avg_Cogongrass_Cover-Lynx_rufus 2.6212 1.0159 384
## Avg_Cogongrass_Cover-Didelphis_virginiana 2.9102 1.0568 321
## Avg_Cogongrass_Cover-Sylvilagus_floridanus 1.7769 1.0422 296
## Avg_Cogongrass_Cover-Meleagris_gallopavo 2.2053 1.0324 337
## Avg_Cogongrass_Cover-Sciurus_carolinensis 2.6704 1.0391 305
## Tree_Density-Canis_latrans -0.8898 1.0164 262
## Tree_Density-Procyon_lotor -0.3249 1.0263 371
## Tree_Density-Dasypus_novemcinctus -1.3643 1.0119 214
## Tree_Density-Lynx_rufus 3.1789 1.0137 198
## Tree_Density-Didelphis_virginiana 0.1324 1.0024 605
## Tree_Density-Sylvilagus_floridanus -0.2476 1.0085 338
## Tree_Density-Meleagris_gallopavo 0.4739 1.0299 375
## Tree_Density-Sciurus_carolinensis 0.5703 1.0222 352
## Avg_Canopy_Cover-Canis_latrans 1.4526 1.0035 708
## Avg_Canopy_Cover-Procyon_lotor 3.4995 1.0089 330
## Avg_Canopy_Cover-Dasypus_novemcinctus 4.5188 1.0144 382
## Avg_Canopy_Cover-Lynx_rufus 3.9508 1.0311 360
## Avg_Canopy_Cover-Didelphis_virginiana 6.5335 1.0125 325
## Avg_Canopy_Cover-Sylvilagus_floridanus 8.8186 1.0246 228
## Avg_Canopy_Cover-Meleagris_gallopavo 5.8931 1.0177 260
## Avg_Canopy_Cover-Sciurus_carolinensis 7.4120 1.0391 289
## I(Avg_Cogongrass_Cover^2)-Canis_latrans 5.3447 1.1012 239
## I(Avg_Cogongrass_Cover^2)-Procyon_lotor 5.6796 1.1770 228
## I(Avg_Cogongrass_Cover^2)-Dasypus_novemcinctus 3.0459 1.0153 721
## I(Avg_Cogongrass_Cover^2)-Lynx_rufus 6.0419 1.0388 287
## I(Avg_Cogongrass_Cover^2)-Didelphis_virginiana 2.3742 1.0449 327
## I(Avg_Cogongrass_Cover^2)-Sylvilagus_floridanus 3.1155 1.0559 395
## I(Avg_Cogongrass_Cover^2)-Meleagris_gallopavo 2.8144 1.0749 156
## I(Avg_Cogongrass_Cover^2)-Sciurus_carolinensis 3.3243 1.0084 689
## avg_veg_height-Canis_latrans 1.0697 1.0103 525
## avg_veg_height-Procyon_lotor 1.4885 1.0194 521
## avg_veg_height-Dasypus_novemcinctus 1.8386 1.0130 586
## avg_veg_height-Lynx_rufus 1.2262 1.0366 306
## avg_veg_height-Didelphis_virginiana 1.2609 1.0122 553
## avg_veg_height-Sylvilagus_floridanus 1.3267 1.0175 471
## avg_veg_height-Meleagris_gallopavo 1.7760 1.0175 428
## avg_veg_height-Sciurus_carolinensis 2.3835 1.0037 459
##
## Detection (logit scale):
## Mean SD 2.5% 50% 97.5% Rhat
## (Intercept)-Canis_latrans -2.5674 0.1902 -2.9593 -2.5650 -2.2046 1.0058
## (Intercept)-Procyon_lotor -2.2224 0.1610 -2.5405 -2.2200 -1.9132 1.0097
## (Intercept)-Dasypus_novemcinctus -1.7109 0.1873 -2.0857 -1.7060 -1.3577 1.0055
## (Intercept)-Lynx_rufus -3.4535 0.3320 -4.1269 -3.4495 -2.8369 1.0092
## (Intercept)-Didelphis_virginiana -2.4910 0.2922 -3.0670 -2.4931 -1.9078 1.0044
## (Intercept)-Sylvilagus_floridanus -3.0651 0.2749 -3.6484 -3.0535 -2.5686 1.0112
## (Intercept)-Meleagris_gallopavo -3.4161 0.4751 -4.3549 -3.4278 -2.4904 1.0327
## (Intercept)-Sciurus_carolinensis -2.6820 0.3352 -3.3358 -2.6759 -2.0412 1.0027
## shrub_cover-Canis_latrans -0.2897 0.2367 -0.7712 -0.2876 0.1699 1.0021
## shrub_cover-Procyon_lotor 0.2931 0.1624 -0.0362 0.2933 0.6039 0.9998
## shrub_cover-Dasypus_novemcinctus 1.0294 0.3185 0.3902 1.0381 1.6375 1.0041
## shrub_cover-Lynx_rufus 0.0770 0.3568 -0.6265 0.0807 0.7496 1.0258
## shrub_cover-Didelphis_virginiana 1.1253 0.3679 0.4348 1.1155 1.8783 1.0123
## shrub_cover-Sylvilagus_floridanus 0.5914 0.3945 -0.1793 0.5892 1.3560 1.0266
## shrub_cover-Meleagris_gallopavo -0.3542 0.4470 -1.2399 -0.3535 0.5068 1.0325
## shrub_cover-Sciurus_carolinensis 1.1132 0.4195 0.2694 1.1141 1.9208 1.0024
## veg_height-Canis_latrans -0.5496 0.1869 -0.9158 -0.5471 -0.1886 1.0029
## veg_height-Procyon_lotor 0.3734 0.1214 0.1410 0.3726 0.6133 1.0040
## veg_height-Dasypus_novemcinctus 0.2940 0.1373 0.0362 0.2896 0.5661 1.0017
## veg_height-Lynx_rufus 0.1681 0.2422 -0.3144 0.1770 0.6245 1.0142
## veg_height-Didelphis_virginiana 0.5068 0.2392 0.0400 0.5012 0.9837 1.0013
## veg_height-Sylvilagus_floridanus 0.1728 0.2514 -0.3378 0.1761 0.6582 1.0074
## veg_height-Meleagris_gallopavo -0.0933 0.4329 -1.0389 -0.0866 0.7345 1.0301
## veg_height-Sciurus_carolinensis 0.1722 0.2227 -0.2494 0.1666 0.6169 1.0057
## week-Canis_latrans 0.4501 0.2457 -0.0132 0.4410 0.9498 1.0022
## week-Procyon_lotor 0.1574 0.1974 -0.2290 0.1570 0.5486 1.0020
## week-Dasypus_novemcinctus 0.0735 0.2135 -0.3478 0.0715 0.4918 1.0013
## week-Lynx_rufus 0.2658 0.2940 -0.3177 0.2552 0.8599 1.0044
## week-Didelphis_virginiana 0.0558 0.3106 -0.5949 0.0638 0.6354 1.0049
## week-Sylvilagus_floridanus 0.0437 0.2928 -0.5539 0.0526 0.6104 1.0031
## week-Meleagris_gallopavo -0.0902 0.3399 -0.8179 -0.0672 0.4993 1.0040
## week-Sciurus_carolinensis 0.5423 0.3287 -0.0303 0.5130 1.2597 1.0003
## I(week^2)-Canis_latrans -0.1951 0.1028 -0.4041 -0.1934 0.0010 1.0002
## I(week^2)-Procyon_lotor -0.1078 0.0870 -0.2782 -0.1063 0.0630 1.0019
## I(week^2)-Dasypus_novemcinctus -0.1594 0.1021 -0.3651 -0.1583 0.0381 1.0069
## I(week^2)-Lynx_rufus -0.2042 0.1432 -0.5010 -0.1988 0.0620 1.0236
## I(week^2)-Didelphis_virginiana -0.3660 0.2033 -0.8310 -0.3441 -0.0269 1.0239
## I(week^2)-Sylvilagus_floridanus -0.1660 0.1507 -0.4774 -0.1602 0.1217 1.0023
## I(week^2)-Meleagris_gallopavo -0.3754 0.2378 -0.9496 -0.3444 -0.0059 1.0174
## I(week^2)-Sciurus_carolinensis -0.1974 0.1398 -0.4950 -0.1904 0.0562 1.0009
## ESS
## (Intercept)-Canis_latrans 1332
## (Intercept)-Procyon_lotor 1798
## (Intercept)-Dasypus_novemcinctus 1551
## (Intercept)-Lynx_rufus 565
## (Intercept)-Didelphis_virginiana 762
## (Intercept)-Sylvilagus_floridanus 1084
## (Intercept)-Meleagris_gallopavo 346
## (Intercept)-Sciurus_carolinensis 566
## shrub_cover-Canis_latrans 765
## shrub_cover-Procyon_lotor 1561
## shrub_cover-Dasypus_novemcinctus 867
## shrub_cover-Lynx_rufus 532
## shrub_cover-Didelphis_virginiana 688
## shrub_cover-Sylvilagus_floridanus 559
## shrub_cover-Meleagris_gallopavo 406
## shrub_cover-Sciurus_carolinensis 433
## veg_height-Canis_latrans 824
## veg_height-Procyon_lotor 1903
## veg_height-Dasypus_novemcinctus 2365
## veg_height-Lynx_rufus 722
## veg_height-Didelphis_virginiana 1317
## veg_height-Sylvilagus_floridanus 785
## veg_height-Meleagris_gallopavo 317
## veg_height-Sciurus_carolinensis 1196
## week-Canis_latrans 1661
## week-Procyon_lotor 2428
## week-Dasypus_novemcinctus 2587
## week-Lynx_rufus 1273
## week-Didelphis_virginiana 1429
## week-Sylvilagus_floridanus 1242
## week-Meleagris_gallopavo 874
## week-Sciurus_carolinensis 1466
## I(week^2)-Canis_latrans 1802
## I(week^2)-Procyon_lotor 2293
## I(week^2)-Dasypus_novemcinctus 1888
## I(week^2)-Lynx_rufus 1031
## I(week^2)-Didelphis_virginiana 635
## I(week^2)-Sylvilagus_floridanus 1105
## I(week^2)-Meleagris_gallopavo 313
## I(week^2)-Sciurus_carolinensis 1567
names(ms_fullQ_fullQ)
## [1] "rhat" "beta.comm.samples" "alpha.comm.samples"
## [4] "tau.sq.beta.samples" "tau.sq.alpha.samples" "beta.samples"
## [7] "alpha.samples" "z.samples" "psi.samples"
## [10] "like.samples" "sigma.sq.psi.samples" "beta.star.samples"
## [13] "re.level.names" "ESS" "X"
## [16] "X.p" "X.p.re" "X.re"
## [19] "y" "call" "n.samples"
## [22] "x.names" "sp.names" "x.p.names"
## [25] "n.post" "n.thin" "n.burn"
## [28] "n.chains" "pRE" "psiRE"
## [31] "run.time"
str(ms_fullQ_fullQ$beta.samples)
## 'mcmc' num [1:4000, 1:72] -0.195 -0.47 -0.722 -2.076 -0.625 ...
## - attr(*, "mcpar")= num [1:3] 1 4000 1
## - attr(*, "dimnames")=List of 2
## ..$ : NULL
## ..$ : chr [1:72] "(Intercept)-Canis_latrans" "(Intercept)-Procyon_lotor" "(Intercept)-Dasypus_novemcinctus" "(Intercept)-Lynx_rufus" ...
mean(ms_fullQ_fullQ$beta.samples[, 5] > 0) # effect of ? on occupancy
## [1] 0.001
MCMCplot(ms_fullQ_fullQ$beta.samples, ref_ovl = TRUE, ci = c(50, 95)) # Occupancy
MCMCplot(ms_fullQ_fullQ$alpha.samples, ref_ovl = TRUE, ci = c(50, 95)) # Detection
## Occupancy
# Total number of parameters
n_params <- ncol(ms_fullQ_fullQ$beta.samples)
# Choose how many parameters to plot at a time
chunk_size <- 10
# Split and plot
for (i in seq(1, n_params, by = chunk_size)) {
end <- min(i + chunk_size - 1, n_params)
param_names <- colnames(ms_fullQ_fullQ$beta.samples)[i:end]
# Set filename
file_name <- paste0("MCMCplot_Occupancy_Params_", i, "_to_", end, ".png")
# Save plot to PNG
png(filename = file_name, width = 1200, height = 800, res = 150)
MCMCplot(ms_fullQ_fullQ$beta.samples[, param_names],
ref_ovl = TRUE,
ci = c(50, 95),
main = paste0("Occupancy Parameters: ", i, " to ", end))
dev.off()
}
## Detection
# Number of parameters
n_params <- ncol(ms_fullQ_fullQ$alpha.samples)
# Number of parameters to plot at a time
chunk_size <- 10
# Split and plot
for (i in seq(1, n_params, by = chunk_size)) {
end <- min(i + chunk_size - 1, n_params)
param_names <- colnames(ms_fullQ_fullQ$alpha.samples)[i:end]
# Set filename
file_name <- paste0("MCMCplot_Detection_Params_", i, "_to_", end, ".png")
# Save plot to PNG
png(filename = file_name, width = 1200, height = 800, res = 150)
MCMCplot(ms_fullQ_fullQ$alpha.samples[, param_names],
ref_ovl = TRUE,
ci = c(50, 95),
main = paste0("Detection Parameters: ", i, " to ", end))
dev.off()
}
species_index <- which(dimnames(data_list$y)$species == "Procyon_lotor")
# Create a set of values across the range of observed cogongrass values
cogon.pred.vals <- seq(min(data_list$occ.covs$Avg_Cogongrass_Cover),
max(data_list$occ.covs$Avg_Cogongrass_Cover),
length.out = 100)
# Scale predicted values by mean and standard deviation used to fit the model
cogon.pred.vals.scale <- (cogon.pred.vals - mean(data_list$occ.covs$Avg_Cogongrass_Cover)) /
sd(data_list$occ.covs$Avg_Cogongrass_Cover)
# Predict occupancy across cogongrass cover values at mean values of all other variables
pred.df <- as.matrix(data.frame(intercept = 1, Avg_Cogongrass_Cover =
cogon.pred.vals.scale, 'I(Avg_Cogongrass_Cover^2)' = 0,
Cogon_Patch_Size = 0, Veg_shannon_index = 0,
total_shrub_cover = 0, Tree_Density = 0,
Avg_Canopy_Cover = 0, avg_veg_height = 0, Auth = 0))
out.pred <- predict(ms_fullQ_fullQ, pred.df, species = species_index)
## Warning in predict.msPGOcc(ms_fullQ_fullQ, pred.df, species = species_index):
## 'species' is not an argument
str(out.pred)
## List of 3
## $ psi.0.samples: num [1:4000, 1:8, 1:100] 0.4047 0.2256 0.297 0.0707 0.2208 ...
## $ z.0.samples : int [1:4000, 1:8, 1:100] 1 0 0 0 0 1 0 1 1 1 ...
## $ call : language predict.msPGOcc(object = ms_fullQ_fullQ, X.0 = pred.df, species = species_index)
## - attr(*, "class")= chr "predict.msPGOcc"
str(out.pred$psi.0.samples)
## num [1:4000, 1:8, 1:100] 0.4047 0.2256 0.297 0.0707 0.2208 ...
psi.0.quants <- apply(out.pred$psi.0.samples, c(3), function(x) quantile(x, prob = c(0.025, 0.5, 0.975)))
str(psi.0.quants)
## num [1:3, 1:100] 0.0017 0.12 0.8617 0.0017 0.1196 ...
## - attr(*, "dimnames")=List of 2
## ..$ : chr [1:3] "2.5%" "50%" "97.5%"
## ..$ : NULL
psi.plot.dat <- data.frame(
psi.med = psi.0.quants[2, ],
psi.low = psi.0.quants[1, ],
psi.high = psi.0.quants[3, ],
Avg_Cogongrass_Cover = cogon.pred.vals
)
str(psi.plot.dat)
## 'data.frame': 100 obs. of 4 variables:
## $ psi.med : num 0.12 0.12 0.123 0.12 0.121 ...
## $ psi.low : num 0.0017 0.0017 0.00195 0.00194 0.00212 ...
## $ psi.high : num 0.862 0.848 0.843 0.839 0.839 ...
## $ Avg_Cogongrass_Cover: num -0.708 -0.675 -0.641 -0.608 -0.575 ...
ggplot(psi.plot.dat, aes(x = Avg_Cogongrass_Cover, y = psi.med)) +
geom_ribbon(aes(ymin = psi.low, ymax = psi.high), fill = "grey70") +
geom_line() +
theme_bw() +
scale_y_continuous(limits = c(0, 1)) +
labs(x = "Average Cogongrass Cover", y = "Occupancy Probability") +
ggtitle("Procyon_lotor Occupancy vs Cogongrass Cover")