DOI: 10.5281/zenodo.18656864
title: Human disturbance, prey availability and refuge cover shape wolf movements in anthropized landscapes

description: This repository contains the cleaned dataset and R scripts necessary to reproduce the analyses presented in the study "Human disturbance, prey availability and refuge cover shape wolf movements in anthropized landscapes", accepted in Behavioral Ecology.

The dataset includes processed movement data of wolves in human-dominated landscapes, specifically prepared for the analysis of daily movement patterns. It contains descriptive variables and environmental predictors used in the statistical models, but does not include sensitive information such as raw GPS coordinates (latitude/longitude) of wolf locations, in compliance with Spanish legislation protecting this endangered species (Spanish Royal Decree 139/2011 and Ministerial Order TED/980/2021). Raw data supporting the findings of this study are available upon request from A.RE.NA. Asesores en Recursos Naturales, S.L., but are not publicly available due to their sensitive nature, as they contain precise locations of wolves and packs.

DATA:

WOLF_DAILY_MOV_DATABASE.csv: Cleaned dataset used for all analyses, including daily movement metrics and spatial covariates (human disturbance, refuge cover, prey availability, etc.).

WOLF_DAILY_MOV_DATABASE_metadata.csv: Variable description and units of each of the columns included in WOLF_DAILY_MOV_DATABASE.csv

CODE SCRIPTS AND WORKFLOW:

Workflow Recommendation: Run scripts sequentially from 00 to 09. Scripts 02 and 06 are computationally intensive and may require HPC resources.



00_Makefile.RMaster control script that sources all analysis scripts in the correct order

01_Wolf_Daily_Tracks.RCreates and filters daily wolf tracks from GPS collar data, calculates movement metrics (daily distance, net displacement, straightness index), and saves individual shapefiles

02_Refuge_DailyMov.RExtracts refuge habitat predictors for each daily track buffer using landscape metrics (area, clumpiness, cohesion, density, fractal dimension, patch size) - computationally intensive

03_Spatial_Predictors.RExtracts spatial predictors: Terrain Ruggedness Index (TRI), human population density, road lengths, and settlement counts for each daily track buffer

04_Data_Cleaning.RCleans and integrates all predictor datasets, calculates derived metrics (road densities, settlement densities, percentage refuge cover), and creates the master database

05_Exploratory_Analysis.RPerforms exploratory analysis: distribution checks, correlation assessment, PCA on refuge variables to reduce dimensionality, and creates spatial grid for random effects

06_Mov_BRMS.RFits Bayesian regression models using brms for three response variables (daily distance, net displacement, straightness index) with hierarchical structure and spatial random effects

07_BRM_Dist_Visualization.RVisualizes model diagnostics, marginal effects, and variable importance for the daily distance model

08_BRM_NetDisp_Visualization.RVisualizes model diagnostics, marginal effects, and variable importance for the net displacement model

09_BRM_Stri_Visualization.RVisualizes model diagnostics, marginal effects, and variable importance for the straightness index model





SOFTWARE VERSIONS

R version 4.4.0 (or later)

Core packages:



dplyr: 1.1.4

ggplot2: 3.4.4

tidyr: 1.3.0

readr: 2.1.4

lubridate: 1.9.3


Spatial packages:



sf: 1.0-14

raster: 3.6-26

terra: 1.7-55

sp: 2.1-1

mapview: 2.11.0


Landscape ecology:



landscapemetrics: 1.5.7


Bayesian modeling:



brms: 2.20.4

rstan: 2.32.3

bayestestR: 0.13.1


Parallel computing:



foreach: 1.5.2

doParallel: 1.0.17

parallel: base


Multivariate analysis:



FactoMineR: 2.9

factoextra: 1.0.7


Model diagnostics:



performance: 0.10.8

DHARMa: 0.4.6

spdep: 1.2-8

spatialreg: 1.2-3


Visualization & reporting:



sjPlot: 2.8.15

ggpubr: 0.6.0

corrplot: 0.92

webr: 0.1.5

writexl: 1.4.2

tictoc: 1.2