DOI: 10.5061/dryad.nvx0k6f2v
title: Global variation in zooplankton niche divergence across ocean basins

description: Modelling responses to climate change assume zooplankton populations
 remain similar over time with little adaptation (niche conservatism).
 Oceanic barriers, genetic, phenotypic variation and species interactions
 in cosmopolitan species could drive niche divergence within species. We
 assess niche divergence among 224 globally distributed species across the
 seven main ocean basins. There were 357 diverged niches out of 828 ocean
 basin comparisons. The proportion of diverged niches varied both across
 and within phyla. Copepoda (156 of 223 species) were used to test for
 niche divergence between same species populations across different
 environmental gradients. Global niche divergence was found to be more
 likely for species in colder temperatures and near shore environments.
 Opposing temperature responses were found for four comparisons which may
 relate to the different connectivity patterns between them. This study
 demonstrates adaptive potential across environmental-niche gradients,
 which must be considered when modelling population responses to climate
 change.
description: Both biological and environmental data are freely
 available for download. The zooplankton data are
 available from the 'Zoobase' dataset https://zenodo.org/records/5101349. This is a collated reseource of all observation records for the main groups of meso-zooplankton  The environmental data were extracted as monthly climatologies from the World Ocean Atlas (2022). Bathymetric depth were extracted from GEBCO’s current gridded bathymetric data set (2024). Monthly climatologies of chlorophyll-a were extracted from the globcolour database (http://www.globcolour.info/). The repository contains code to each of the four main steps of the manuscript. Here we provide a detailed description to replicate the results in the manuscript. We 1) First extract the presences from the 'Zoobase' database and retain species present when n &gt; 50 in two ocean basins, 2) Perform an ensemble model on each species for the global presence distribution in teh dataset, 3) Extract observations of a species from paired ocean basin areas to examine niche divergence, 4) Use the results of the global ensemble model and the binary niche divergence/ non-divergence classifier to perform a heriarchical generalised additive model. 
description: # Global variation in zooplankton niche divergence across ocean basins
 [https://doi.org/10.5061/dryad.nvx0k6f2v](https://doi.org/10.5061/dryad.nvx0k6f2v) ## Description of the data and file structure The repository contains code to each of the four main steps of the manuscript. Here we provide a detailed description to replicate the results in the manuscript. We 1) First extract the presences from the 'Zoobase' database and retain species present when n &gt; 50 in two ocean basins, 2) Perform an ensemble model on each species for the global presence distribution in the dataset, 3) Extract observations of a species from paired ocean basin areas to examine niche divergence, 4) Use the results of the global ensemble model and the binary niche divergence/ non-divergence classifier to perform a heriarchical generalised additive model.  Main Data files and RScripts to replicated the analysis in the manuscript: 1\. "regions.csv";" glob_species_extract_1.R" Download Zoobase from the zenodo repository 2\. "SAAR.csv"; "env.tif"; "envdat.csv"; "Biomod_2.R" 3\. "SAAR.csv";"bgall.csv";"env.tif","Niche_overlap_3.R" 4\. "all_dat_mod.csv";"HGAM_4.R" ### Files and variables Missing values are assigned "NA" #### File: regions.csv **Description:** A file used to generate a raster for ocean basins to extract observations from Zoobase ##### Variables * x: Longitude * y: Latitude * tst: Ocean Basin Code #### File: all\_dat\_mod.csv **Description:** The final niche divergence classification of species and paired area comparisons ##### Variables * Species: Species name * phylum: Phylum * class: Class * order: Order * family: Family * area: Paired area code. Each Ocean basin is defined by 2 character abbreviation. Eg - South Atlantic 'SA' & Arctic Ocean 'AR'. Paired area = 'SA_AR' * N1: Number of occurrences in area 1after spatial filtering * N2: Number of occurrences in area 2 after spatial filtering * DIV: Binary classifier of niche divergence of two populations 'Y' = divergence, 'N' = Conservatism or neutral niches * ENS.D: Ensemble niche overlap value between 0-1 * ENS.BG1: Mean ensemble background of niche overlap for area 1 * ENS.BG2: Mean ensemble background of niche overlap for area 2 * ENS.SD1: Mean Standard deviation background of niche overlap for area 1 * ENS.SD2: Mean Standard deviation background of niche overlap for area 2 * Bathymetry: Weighted mean niche for species - Bathymetric depth (m) * Temperature: Weighted mean niche for species - Temperature (°C) * Chl-a: Weighted mean niche for species - Chlorophyll-a (mg m-3) * Mixed Layer Depth: Weighted mean niche for species (Mixed Layer Depth (m)) * Nitrate: Weighted mean niche for species - Nitrate (µmol/kg) * Salinity: Weighted mean niche for species - Salinity (unitless) * Wind Stress: Weighted mean niche for species - Wind stress (N m-2) #### File: SAAR.csv **Description:** Species occurrences for those species found with populations in the South Atlantic (SA) and Arctic Ocean (AR) ##### Variables * ID: ID number * x: Longitude * y: Latitude * Year: Year of observation * Month: Month of observation * Day: Day of observation * Phylum: Phylum * Class: Class * Order: Order * Family: Family * Genus: Genus * Species: Species * chl: Climatological value of Chlorophyll-a at observation (mg m-3) * sil: Climatological value of Silicate at observation (µmol/kg) * sst: Climatological value of Temperature at observation (°C) * sal: Climatological value of Salinity at observation * nit: Climatological value of Nitrate at observation(µmol/kg) * mld: Climatological value of Mixed Layer Depth at observation (m) * dist: Distance from shoreline for observation (m) * ws: Climatological value of Wind Stress at observation (N m-2) * dep: Bathymetry measurement at observation (m) * oxy: Climatological value of Dissolved Oxygen at observation (µmol/kg) * bg: Background code used to extract targeted background locations * obasin: Ocean basin code observation was taken from #### File: envdat.csv **Description:** The environmental data (climatologies) used to extract background observations for the ensemble modelling using Biomod ##### Variables * ID: ID number * x: Longitude * y: Latuitude * M: Month * chl: Codes as above in SAAR.csv * sil: * sst: * sal: * nit: * mld: * ws: * dep: * dist: * bg: #### File: bgall.csv **Description:** The background data unrolled climatologies with assigned ocean basins ##### Variables * obasin: Codes as above for SAAR.csv * x: * y: * M: * chl: * sil: * sst: * sal: * nit: * mld: * dist: * ws: * dep: ## Code/software R: files " glob_species_extract_1.R" R scripts to extract species from the zoobase dataset and subset to species present in sufficient numbers within each ocean basin.  "ensemble_2.R" R scripts to perform the ensemble modelling using the R package **biomod2. **We show the process for a subset of 7 species. this is repeated for all 223 species in the database.  "Niche_overlap_3.R" R scripts to perform the background similarity test (niche similarity) between pairs of populations in different ocean basins. Shown here is an example for species with populations in the South Atlantic and Arctic Ocean. "HGAM_4.R" R scripts to perform the heirarchical generalised additive model.