<?xml-model href='http://www.tei-c.org/release/xml/tei/custom/schema/relaxng/tei_all.rng' schematypens='http://relaxng.org/ns/structure/1.0'?><TEI xmlns="http://www.tei-c.org/ns/1.0">
	<teiHeader>
		<fileDesc>
			<titleStmt><title level='a'>Synchronized seasonal excretion of multiple coronaviruses coincides with high rates of coinfection in immature bats: Code.</title></titleStmt>
			<publicationStmt>
				<publisher>Zenodo</publisher>
				<date>01/01/2025</date>
			</publicationStmt>
			<sourceDesc>
				<bibl> 
					<idno type="par_id">10674325</idno>
					<idno type="doi">10.5281/zenodo.15399029</idno>
					
					<author>Alison Peel</author><author>Manuel Ruiz-Aravena</author><author>Karan Kim</author><author>Braden Scherting</author><author>Caylee Falvo</author><author>Daniel E Crowley</author><author>Vincent Munster</author><author>Edward J Annand</author><author>Karren Plain</author><author>Devin Jones</author><author>Tamika J Lunn</author><author>Adrienne Dale</author><author>Andrew Hoegh</author><author>John-Sebastian Eden</author><author>Raina Plowright</author>
				</bibl>
			</sourceDesc>
		</fileDesc>
		<profileDesc>
			<abstract><ab><![CDATA[{"Abstract":["Synchronized seasonal excretion of multiple coronaviruses coincides with high rates of coinfection in immature bats.\n\nThis repo contains instructions and source code for reproducing the statistical analyses in the manuscript.\n\nRepo Contents\n\n\n\nscripts: contains the source .R and .stan files to reproduce the anaysis. Each file is detailed below in the specific sections corresponding to the statistical analyses.\n\ndata: contains the raw source data and model generated output.\n\nfigures: contains the final output figures from the manuscript. These can be recreated with the CovOZ_Figures_Submission_Clean.R script.\n\n\n1. System Requirements\n\nHardware Requirements\n\nOur source code requires only a standard computer. Much of the Markov chain Monte Carlo code is run in parallel so a computer with ample memory and multiple cores can be advantageous. The runtimes below are generated using a macbook with the recommended specs (64 GB RAM, 8 cores at 2.7 GHz). The code will also work on linux or windows computer.\n\nSoftware Requirements\n\nReproducing the statistical analyses requires a current version of R and stan. We use version 4.4.1 of R and version 2.32.2 of stan.\n\nPackage dependencies and versions\n\nUsers will need the following packages install the following packages to execute the code. Our versions are effective October 1, 2024\n\ntidyverse 2.0.0\nlubridate 1.9.3\nstringr 1.5.1\nrstan 2.32.6\ncowplot 1.1.3\nggtext 0.1.2\njpeg 0.1-10\nscales 1.3.0\ntictoc 1.2.1\n\n\n2. Installation Guide\n\nRunning the analysis requires:\n\n\n\ninstalling R. Depending on wifi speeds, installing R usually takes a few minutes.\n\ninstalling stan. Depending on wifi speeds, installing stan usually takes a few minutes.\n\ninstalling the necessary R packages (listed above). Depending on wifi speeds, installing packages usually takes about 30 seconds per package.\n\n\n3. Demo\n\nThis source code is not an R package with a formal demo, but rather source code is included for the various analyses in section 4.\n\n4. Instructions for Use\n\n4.1 Coinfection Analysis\n\nRuns chi-squared tests on coinfections of beta 2d.iv and beta 2d.v. Generates summary statistics, test statistics, and p-values from manuscript.\n\n\n\ninput files: individual_variant_covariates.csv\n\nscript file: coinfection_final.R\n\nrun time: approximately 1 second\n\n\n4.2 Individual Level Dynamics of Infection: Dynamic Binary Regression\n\nRuns individual level dynamic binary regression models. Produces output file that can recreate figures.\n\n\n\ninput files: individual_variant_covariates.csv\n\nscript files:\n\n\n\nlogistic_curves_final.R\n\nGP_regression.stan\n\n\n\noutput files: logistic_curve_out.RData\n\nrun time: approximately 66 minutes\n\n\n4.3 Dynamics of Circulation at the Population Level\n\nRuns combined (individual and pooled data) dynamic models. Produces output file that can recreate figures.\n\n\n\ninput files: combined_out_variant.csv\n\nscript files:\n\n\n\ncluster_curves_final.R\n\nGP_withLL.stan\n\n\n\noutput files: cluster_curves.csv\n\nrun time: approximately 25 minutes\n\n\n4.4 Manuscript Figures\n\nCombined script that uses output files created by previous scripts to recreate all figures in the manuscript.\n\n\n\n\n\ninput files:\n\n\n\nmodel_output/cluster_curves.csv\n\ncombined_out_variant.csv\n\nindividual_variant_covariates.csv\n\nmodel_output/logistic_curve_out.RData\n\n\n\n\n\nscript files:\n\n\n\nCovOZ_Figures_Submission_Clean.R\n\n\n\n\n\noutput files:\n\n\n\nFigure2_final.png\n\nFigure3_final.png\n\nFigure4_A-D_final.png\n\nFigure6_AP.png\n\nFigure7.png\n\nSIFigure8.png\n\nSIFigure9.png\n\n\n\n\n\nrun time: approximately 16 seconds\n\n\n\n4.5 Model Comparison Integrated\n\nCompares LOOIC values for sets of model frameworks.\n\n\n\ninput files: combined_out_variant.csv\n\nscript files:\n\n\n\nPred_Comparisons.R\n\nGP_withLL.stan\n\n\n\noutput files: preds.RData\n\nrun time: approximately 2 hours\n\n\n4.6 Model Comparison Individual\n\nCompares LOOIC values for sets of model frameworks.\n\n\n\ninput files: combined_out_variant.csv\n\nscript files:\n\n\n\nlogistic_curves_loo.R\n\nGP_regression.stan\n\nGP_regression_add.stan\n\nGP_regression_interact.stan\n\n\n\noutput files:\n\n\n\nlogistic_curve_loo_age.RData\n\nlogistic_curve_loo_age_add_sex.RData\n\nlogistic_curve_loo_age_interact_sex.RData\n\n\n\nrun time: approximately 6:45 hours"]}]]></ab></abstract>
		</profileDesc>
	</teiHeader>
	<text><body><div/></body></text>
</TEI>
