Data from: Dynamics of mixed-ploidy populations under demographic and environmental stochasticities
Data files
Jan 02, 2025 version files 2.21 GB
-
01_RevisionProcessing.r
2.86 KB
-
02_Alternative-GeometricMean.R
5.15 KB
-
functions.zip
8.40 KB
-
Gaynor2024.Rproj
205 B
-
output.zip
1.28 GB
-
plots.zip
933.43 MB
-
README.md
12.90 KB
-
sbatch.zip
3.50 KB
-
set1.zip
2.46 KB
-
set2.zip
2.52 KB
-
set3.zip
2.42 KB
-
set4.zip
2.42 KB
Abstract
The population dynamics of autopolyploids – organisms with more than two genome copies of a single species – and their diploid progenitors have been extensively studied. The acquisition of multiple genome copies is heavily influenced by stochasticity, which strongly suggests the efficacy of a probabilistic approach to examine the long-term dynamics of a population with multiple cytotypes. Yet, our current understanding of the dynamics of autopolyploid populations has not incorporated stochastic population dynamics and coexistence theory. To investigate the factors contributing to the probability and stability of coexisting cytotypes, we designed a new population dynamics model that incorporates demographic and environmental stochasticities to simulate the formation, establishment, and persistence of diploids, triploids, and autotetraploids in the face of gene flow among cytotypes. Contrary to previous theoretical research, increased selfing rates and pronounced reproductive isolation promote coexistence of multiple cytotypes. In stressful environments and with strong competitive effects among cytotypes, these dynamics are more complex; our stochastic modeling approach reveals the resulting intricacies that give autotetraploids competitive advantage over their diploid progenitors. Our work is fundamental to a better understanding of the dynamics of coexistence of multiple cytotypes.
README: Dynamics of mixed-ploidy populations under demographic and environmental stochasticities
This dataset contains R scripts to simulate and analyze simulation output associated with:
Gaynor ML, Kortessis N, Soltis DE, Soltis PS, and Ponciano JM. 2024. Dynamics of mixed-ploidy populations under demographic and environmental stochasticities.
The simulation framework is available in our R package AutoPop: https://github.com/mgaynor1/AutoPop/, also available via zenodo: 10.5281/zenodo.14147297.
Summary
In this study, we designed a new stochastic stage-structured matrix population dynamics model for diploid, triploid, and autotetraploid. We then utilize this model to characterize the effects of reproductive isolation, cytotype interactions, and variation in the environment on: (1) the probability that diploids and tetraploids coexist and (2) the resulting stability of coexistence.
Due to the size of our output files, we do not provide all datafiles here and only provide the files needed to make each figure.
Authors
Michelle L. Gaynor, shellyleegaynor@gmail.com
Nicholas Kortessis, kortessn@wfu.edu
Douglas E. Soltis, dsoltis@ufl.edu
Pamela S. Soltis, psoltis@flmnh.ufl.edu
Jose Miguel Ponciano, josemi@ufl.edu
Code Maintenance
Code is maintained and written by Michelle L. Gaynor, email: shellyleegaynor@gmail.com.
Folders and Files Description
First, simulations can be run based on the provided bash scripts found in the "sbatch_scripts/" folder. Once these simulations are run, they can be processed with '01_RevisionProcessing.R' and '02_Alternative-GeometricMean.R', which uses the functions found in 'functions.zip' to create the files found in 'output.zip'.
Output files indicate which model the summary statistic belongs to based on rho.value (0, 0.5, and 1), env.value (low, medium, and high), gam.density.type (all & like-cytotype), is.density.type (all & like-cytotype), s.value (0 - 1, by 0.1; 11 values), and mc.value (0 - 1, by 0.1; 11 values). Most columns are described below to help you fully understand the meaning of the remaining columns in our output files. However, for many of these columns we recommend reviewing the code used to generate these files (found here) or reviewing our extensive markdown associated with our packages. For output files found in 'stability/', please see mars.cls() and stability() for outputs meaning. For output files found in 'one_rep/' see gen.iter.f.choosy() for outputs meaning. The github linked here is available via zenodo: 10.5281/zenodo.14147297, thus guaranteeing the preservation of our package needed to generate these outputs and the additional documentation.
For stability output files, columns may include:
- A, vector of length p (p = number of species) containing the estimates of the intrinsic rate of natural increase of each species.
- B, a matrix of p x p estimates where the diagonal elements represent the intra-specific, density-dependent effects. The elements b_{ij} gives the effect of the abundance of species j on per capita growth rate of species i.
- sigma, a matrix of p x p, represents environmental noise variance-covariance matrix.
- C, a vector of estimated coefficients for every covariate representing the effects of every covariate on every species.
- E, vector representing stochastic environmental variability.
- Yhat, estimator of predicted abundance.
- R2, proportion of explained variation in the log scale population abundance for each species.
- R2_D, proportion of variation in the change in one unit of time of the log scale population abundance explained by the model for each species.
- AIC, Akaike information criterion.
- BIC, Bayesian information criterion.
- lnlike, maximized log likelihood of the MAR(1) model.
- var.prop, at stationarity the var.prop is the variance proportion attributable to environmental noise. The smaller the values, the more stable the dynamics.
- mean.return.time & var.return.time, rate at which the transition distribution converges back to the stationary distribution. The less time it takes to return to the stationary distribution, the more stable the population.
- reactivity, measures reaction to perturbations or the distance away from stationary a system moves in response to a disturbance. Again, smaller is better in terms of stability.
- sp.contribs, squared eigenvalue representing the characteristic return rate of the variance of the transition distribution of the estimated MARS(1) Markov Process.
Figures found in our manuscript can be created with the scripts available in 'plots.zip'.
Folders and Files
Directory/
├── README.md
├── Gaynor2024.Rproj # R project file
├── 01_RevisionProcessing.R
├── 02_Alternative-GeometricMean.R
├── functions
| ├── geometricmean.R
| ├── JM-geometricmean.R
| ├── write_one_rep.R
| ├── one.mean.R
| └── stabilitycalc.R
├── output.zip # Only files needed for plots included
| ├── merry2 # Output from 02_Alternative-GeometricMean.R
| ├── means #sum2x and sum4x are the geometric mean 2x and 4x over 500 generations.
| └─── ...
| ├── stability # Output from 01_RevisionProcessing.R, see links above for meaning.
| ├── all
| ├── real.stability.summary # Columns defined above and in linked documentation.
| └── allset-summary.csv
| └─── ...
| ├── stability.summary # Columns defined above and in linked documentation.
| └── allset-summary.csv
| └─── ...
| ├── Aset # Intrinsic rate of natural increase of V1 = diploid, V2 = tetraploid
| └── all_Asets.csv
| └─── ...
| ├── Bmatrix # Files defined in plots/Supplemental/PreProcessing/FigureS6-PreProcessing.R
| ├── cg #BIJ = B12 and B21, where 1 is diploid and 2 is tetraploid. Columns are the effect of the abundance of species j on per capita growth rate of species i.
| └── allset-summary.csv
| └─── ...
| ├── spp # Intra-specific, density-dependent effects of V1 = diploid and V2 = tetraploid.
| └── allset-summary.csv
| └─── ...
| ├── popmeans # Output from 01_RevisionProcessing.R.
| └── means # sum2x and sum4x are the mean 2x and 4x over 500 generations.
| ├── allset-summary.csv
| └─── ...
| └── one_rep # Output from 01_RevisionProcessing.R, see links above for meaning.
| ├── all # sum2x-sum4x = sum of diploids, triploid, and tetraploids; sum2xt = log(sum2x + 1); sum4xt = log(sum4x +1); allsumt = log(allsum + 1)
| └── ssout # see simulation output below for column meaning.
├── plots
| ├── Figures
| ├── Figure01.pdf
| ├── Figure01.pptx
| ├── Figure02.pdf
| ├── Figure02.Rmd
| ├── Figure03.pdf
| ├── Figure03.Rmd
| ├── Figure04.pdf
| ├── Figure04.Rmd
| ├── Figure05.pdf
| ├── Figure05.Rmd
| └── PreProcessing
| ├── Figure02-PreProcessing.R
| ├── Figure04-PreProcessing.R
| └── Figure05-PreProcessing.R
| └── Supplemental
| ├── FigureS1.pdf
| ├── FigureS1.pptx
| ├── FigureS2.pdf
| ├── FigureS2.Rmd
| ├── FigureS3.pdf
| ├── FigureS3.Rmd
| ├── FigureS4.pdf
| ├── FigureS4.Rmd
| ├── FigureS5.pdf
| ├── FigureS5.Rmd
| ├── FigureS6.pdf
| ├── FigureS6.Rmd
| ├── FigureS7.pdf
| ├── FigureS7.Rmd
| ├── FigureS8.pdf
| ├── FigureS8.Rmd
| ├── FigureS9.pdf
| ├── FigureS9.Rmd
| ├── FigureS10.pdf
| ├── FigureS10.Rmd
| ├── FigureS11.pdf
| ├── FigureS11.Rmd
| ├── FigureS12.pdf
| ├── FigureS12.Rmd
| ├── FigureS13.pdf
| ├── FigureS13.Rmd
| ├── FigureS14.pdf
| ├── FigureS14.Rmd
| ├── FigureS15.pdf
| ├── FigureS15.Rmd
| ├── FigureS16.pdf
| ├── FigureS16.Rmd
| └── PreProcessing
| ├── FigureS2_PreProcessing.R
| ├── FigureS5_PreProcessing.R
| └── FigureS6-PreProcessing.R
| └── data
| └── S2data.csv
├── sbatch_scripts # For submitting the 4356 models
| ├── set1.sh
| ├── set2.sh
| ├── set3.sh
| └── set4.sh
├── set1 # gam.density.type = "all", is.density.type = "all"
| ├── set1.R
| └── output # Not included due to file size
| └─── ...
├── set2 # gam.density.type = "like-cytotype", is.density.type = "all"
| ├── set2.R
| └── output # Not included due to file size
| └─── ...
├── set3 # gam.density.type = "all", is.density.type = "like-cytotype"
| ├── set3.R
| └── output # Not included due to file size
| └─── ...
├── set4 # gam.density.type = "like-cytotype". is.density.type = "like-cytotype"
| ├── set4.R
| └── output # Not included due to file size
| └─── ...
Each set includes 4356 parameter sets which represent all combinations of rho (0, 0.5, and 1), environmental variance (low, medium, and high), gamete density dependence type (all & like-cytotype), immature survival density dependence type (all & like-cytotype), selfing rate (0 - 1, by 0.1; 11 values), and mating choice (0 - 1, by 0.1; 11 values). These simulations will return dataframes with the following columns:
- V1: number of immature diploids.
- V2: number of immature triploids.
- V3: number of immature tetraploids.
- V4: number of mature diploids.
- V5: number of mature triploids.
- V6: number of mature tetraploids.
- V7: number of diploid offspring produced during t - 1.
- V8: number of triploid offspring produced during t - 1.
- V9: number of tetraploid offspring produced during t - 1.
- V10: number of gametes per diploid individual at t - 1.
- V11: number of gametes per triploid individual at t - 1.
- V12: number of gametes per tetraploid individual at t - 1.
- gen: generation.
- sum: total number of individuals.
- sum2x: sum of immature and mature diploids.
- sum3x: sum of immature and mature triploids.
- sum4x: sum of immature and mature tetraploids.
- V1a: relative abundance of immature diploids (V1).
- V2a: relative abundance of immature triploids (V2).
- V3a: relative abundance of immature tetraploids (V3).
- V4a: relative abundance of mature diploids (V4).
- V5a: relative abundance of mature triploids (V5).
- V6a: relative abundance of mature tetraploids (V6).
- C2: relative abundance of all diploids (sum2x/sum).
- C3: relative abundance of all triploids (sum3x/sum).
- C4: relative abundance of all tetraploids (sum4x/sum)
- i1e: diploid immature survival probability during t - 1.
- i2e: triploid immature survival probability during t - 1.
- i3e: tetraploid immature survival probability during t - 1.
- m1e: diploid mature survival probability during t - 1.
- m2e: triploid mature survival probability during t - 1.
- m3e: tetraploid mature survival probability during t - 1.
Version of Packages and Software Used
R version 4.3.1 (2023-06-23)
Platform: arch64-apple-darwin20 (64-bit)
Running under: macOS Sonoma 14.4.1
Attached base packages: stats, graphics, grDevices, utils, datasets, methods, base
Other attached packages: AutoPop_1.0.0.1, ggpp_0.5.6, patchwork_1.2.0, knitr_1.45.17, ggridges_0.5.6, gridExtra_2.3, ggExtra_0.10.1, data.table_1.15.2, gtools_3.9.5, ggh4x_0.2.8, ggtext_0.1.2, ggpubr_0.6.0, ggplot2_3.5.0, cowplot_1.1.3, dplyr_1.1.4, stringr_1.5.1
Loaded via a namespace (and not attached): gtable_0.3.4, xfun_0.43, rstatix_0.7.2, vctrs_0.6.5, tools_4.3.1, generics_0.1.3, tibble_3.2.1, fansi_1.0.6, pkgconfig_2.0.3, lifecycle_1.0.4, compiler_4.3.1, munsell_0.5.0, carData_3.0-5, httpuv_1.6.15, htmltools_0.5.8, yaml_2.3.8, pillar_1.9.0, later_1.3.2, car_3.1-2, tidyr_1.3.1, MASS_7.3-60.0.1, abind_1.4-5, mime_0.12,, tidyselect_1.2.1, digest_0.6.35, stringi_1.8.3, purrr_1.0.2, fastmap_1.1.1, grid_4.3.1, colorspace_2.1-0, cli_3.6.2, magrittr_2.0.3, utf8_1.2.4, broom_1.0.5, withr_3.0.0, scales_1.3.0, promises_1.2.1, backports_1.4.1, rmarkdown_2.26, ggsignif_0.6.4, shiny_1.8.1, evaluate_0.23, miniUI_0.1.1.1, rlang_1.1.3, gridtext_0.1.5, Rcpp_1.0.12, xtable_1.8-4, glue_1.7.0, polynom_1.4-1, xml2_1.3.6, rstudioapi_0.16.0, R6_2.5.1
Methods
All simulations were generated and analyzed with code provided in this repository.