R Functions for Binary and Binomial Data Analysis
Author: Mark C. Eisler
eMail: Mark.Eisler@bristol.ac.uk
ORCID = 0000-0001-6843-3345
Installation
You can install the development version of ParaAnita from GitHub with:
# install.packages("devtools")
devtools::install_github("Mark-Eis/ParaAnita")ParaAnita Package Description: –
The ParaAnita R package includes functions intended to address and simplify a number of issues commonly encountered during binary (Bernoulli) and binomial data analysis using generalised linear models. More specifically, ParaAnita does the following: –
Creates contingency tables with
contingency_table(),xcontingency_table().Summarises binary (Bernoulli) and binomial proportion data in contingency tables with
as_binom_contingency(),binom_contingency().Calculates odds ratios, their confidence intervals and associated probabilities with
odds_ratio().Gets, sets or removes the contrasts attribute for selected categorical variables (
factors) within data withget_contrasts(),get_contr_data(),set_contrasts(),set_contrasts<-(),set_contr_treat()andset_contr_treat<-().Gets, sets and manipulates categorical variable contrast
nameswithcontr_colnames(),contr_colnames<-(),contr_colpfx<-(),helm_names()andhelm_names<-().Compares related generalised linear models using various measures with
anova_tbl(),comp_glm(),summanov()anduniv_anova().Collates model results and standard errors, with optional grouping of levels of selected categorical variables, in a format convenient for plotting with
glm_plotlist()andglm_plotdata(), and plots these in individual or faceted plots withggplot.glm_plotdata()andvar_labs().Adds, modifies, removes or selects factors in data with
add_grps(),drop_null(),drop_zero(),expl_fcts(),fct_to_num(), andgood_levels().Simulates Bernoulli and binomial proportion data sets with categorical explanatory variables with
bernoulli_data()andbinom_data().Simplifies statistical analysis with
chsqfish()andstarsig().Provides auxiliary print functions and prints objects derived from ParaAnita S3 methods with
announce(),lf(),print_all()andprint_lf().Tidies up the R workspace with
rm_objects().Includes the dataset:
budworm, from David Collett (1991). Modelling Binary Data. London: Chapman & Hall.