--- name: TeachingStatistics topic: Teaching Statistics maintainer: Paul Northrop email: p.northrop@ucl.ac.uk version: 2024-08-01 source: https://github.com/cran-task-views/TeachingStatistics/ --- This CRAN task view gives information about packages with features that are designed to assist with the teaching of Statistics. It is **not** concerned with the teaching of R itself. A few of these packages are listed in other task views, but only the `r view("Bayesian")` task view has a section devoted explicitly to teaching (Bayesian) Statistics. The packages are grouped into three broad topics: teaching, examination and packages associated with Statistics books. The latter is for books that are general enough to be of potential interest to a wide audience of teachers of Statistics. They should concern models and methods with wide applicability and not be tied closely to a particular application. If you think that a package is missing from the list, or have any other comments or suggestions, then please contact the maintainer, either via e-mail or by submitting an issue or pull request in the GitHub repository linked above. ### Teaching - `r pkg("Rcmdr", priority = "core")` provides a GUI for R, based on the tcltk package. A point-and-click interface loads data and calls R functions to perform the kinds of analyses involved in introductory Statistics courses. More advanced and specialized analysis are also available, some of them via plug-ins. The R commands are shown in the console. See the [The R Commander homepage](https://socialsciences.mcmaster.ca/jfox/Misc/Rcmdr/) for more information. - `r pkg("swirl")` uses the R console to provide an interactive learning environment for students to learn Statistics. Students select courses to download from the `r github("swirldev/swirl_courses")` GitHub page and are provided with immediate feedback as they work. A variety of topics are available, under the general headings of Exploratory Data Analysis, Statistical Inference and Regression Models. Teachers can author and share their own swirl courses using the `r pkg("swirlify")` package. See also the [swirl home page.](https://swirlstats.com/) - `r pkg("mosaic", priority = "core")` contains a wide range of tools to assist in teaching of basic, and more advanced ideas and techniques in mathematics, statistics, computation and modelling. Key aspects are the provision of functions that enable beginners easily to perform tasks that would otherwise be difficult and the use of simulation to illustrate randomization-based inference. See the [Project MOSAIC homepage](http://www.mosaic-web.org) for more information. - `r pkg("xplain")` can be used to provide bespoke interactive interpretations of the output from statistics functions. This information needs to be provided by the instructor in XML format and may contain R code, to tailor the explanation to the specific results. See the [xplain website](https://www.zuckarelli.de/xplain/index.html) for a tutorial and cheatsheet. - `r pkg("animation", priority = "core")` provides functions to produce animations relating to a wide range of topics in Statistics, Data Mining and Machine Learning. These animations, or a sequence of images generated by the user, may be exported to a variety of formats. - `r pkg("gganimate")` animates plots produced by `r pkg("ggplot2")`. It can be used to render the plots into an animation, such as a GIF or MP4 video . - `r pkg("smovie")` provides movies to illustrate concepts in Statistics. Topics covered are: probability distributions; sampling distributions of the mean (cf. central limit theorem), the maximum (cf. extremal types theorem) and the (Fisher transformation of the) correlation coefficient; simple linear regression; hypothesis testing. - `r pkg("visualize")` provides graphs of the pdf/pmf of various continuous and discrete probability distributions, annotated with the mean and variance of the distribution. Shading is used to indicate an interval (lower tail, upper tail, two-tailed or a user-supplied interval) within which the random variable lies with a user-supplied probability. - `r pkg("LearnBayes")` provides functions and to illustrate the essential ideas of Bayesian inference, such as the roles of the prior, likelihood and posterior; posterior predictive checking and predictive inference, and several example datasets. - `r pkg("shinybrms")` provides a shiny app for fitting various types of Bayesian regression models using the [brms](https://paul-buerkner.github.io/brms/) package. Help text leads the user through the steps of uploading a dataset, specifying a likelihood, setting a prior distribution and making inferences about the posterior distribution. See the package [README](https://cran.r-project.org/web/packages/shinybrms/readme/README.html) file and the [Getting started](https://fweber144.github.io/shinybrms/articles/shinybrms.html) page. - `r pkg("TeachingDemos")` Provides a wide range of static and interactive plots to demonstrate statistical concepts, including: coin tossing and dice rolling; confidence intervals; various aspects of hypothesis testing; the central limit theorem; maximum likelihood estimation; scatterplot smoothing; histograms; correlation and simple linear regression; Box-Cox transformation. - `r pkg("distrTeach")` provides plots to illustrate the Central Limit Theorem (CLT) and the Law of Large Numbers (LLN). The effects on the CLT plots of changing inputs can be shown using a Tcl/Tk-based widget. - `r pkg("BetaBit")` provides games for students to play in the R console, including one that involves data-cleaning and regression modelling. See the [BetaBit home page](http://betabit.wiki/) . - `r pkg("DALEX")` provides functions to explore and understand predictive models. The [DALEX GitHub page](https://github.com/ModelOriented/DALEX) includes two teaching-related showcases. - `r pkg("agricolae")` provides functionality assist the teaching of the design and analysis of statistical experiments, with an emphasis on agricultural field experiments. Designs constructed by `r pkg("agricolae")` can be visualised using `r pkg("agricolaeplotr")`. - `r pkg("LearningRlab")` is designed to help teach basic statistics to secondary and baccalaureate students. It has functions that provide step-by-step explanations of statistical calculations and functions that prompt the student to perform their own calculations. See the package vignette for examples. ### Examination - `r pkg("exams", priority = "core")` provides a framework for the automatic random generation of exams and self-study materials from a pool of exercises composed using either Sweave (.Rnw) or R markdown (.Rmd) formats. R code can be used to generate exercise elements dynamically. Questions can be formatted for use in a variety of e-learning platforms or output as documents, for example a PDF file, for which. Scans of PDF answer sheets can be marked automatically. See also the [R/exams homepage](http://www.R-exams.org) - `r pkg("ProfessR")` creates multiple choice exams from a pool of exercises organised in ASCII test files. Multiple versions of an exam can be created by randomizing the questions and the choices of answers. - `r pkg("rqti")` creates exercises and exams in adherence to the QTI v2.1 standard directly from R. Users have the flexibility to render the exercises either locally (using `qti.js`) or integrate them seamlessly into the OPAL learning management system. Exercises can be created as R Markdown files or as `rqti` S4 classes. See also the [rqti homepage](https://shevandrin.github.io/rqti/). - `r pkg("TexExamRandomizer")` enables the randomization of questions created using LaTeX's document class for preparing exams. Spreadsheets containing students' answers can be marked automatically. ### Packages associated with Statistics books The following packages are associated with textbooks that are of potential interest to a general statistical audience, rather than being specific to a particular application area. The general principle for inclusion is that the package is likely to be of direct use in the teaching of statistical methods. Official publisher links are provided where possible and, in some cases, a link to further resources. - `r pkg("ACSWR")`: Tattar, P.N., Suresh, R., and Manjunath, B.G. (2016), [A Course in Statistics With R](https://doi.org/10.1002/9781119152743) , John Wiley and Sons, Inc. - `r pkg("AER")`: Kleiber, C. and Zeileis, A. (2008), [Applied Econometrics with R](https://doi.org/10.1007/978-0-387-77318-6) , Springer Verlag, New York. [Further resources](https://eeecon.uibk.ac.at/~zeileis/teaching/AER/). - `r pkg("arm")`: Gelman, A. and Hill, J. (2007), [Data Analysis Using Regression and Multilevel/Hierarchical Models](https://doi.org/10.1017/CBO9780511790942) , Cambridge University Press. [Further resources](http://www.stat.columbia.edu/~gelman/arm/). - `r pkg("asbio")`: Aho, K. A. (2014), [Foundational and applied statistics for biologists using R](https://www.routledge.com/Foundational-and-Applied-Statistics-for-Biologists-Using-R/Aho/p/book/9781032477411), Routledge. [Further resources](https://www2.cose.isu.edu/~ahoken/book/). - `r pkg("BayesDA", priority = "core")`: Gelman, A., Carlin, J., Stern, H., Dunson, D., Vehtari, A., Rubin, D. (2013), [Bayesian Data Analysis](https://www.crcpress.com/Bayesian-Data-Analysis-Third-Edition/Gelman-Carlin-Stern-Dunson-Vehtari-Rubin/p/book/9781439840955) , Third Edition. New York: Chapman and Hall/CRC. [Further resources](http://www.stat.columbia.edu/~gelman/book/). - `r pkg("Bolstad")`: Bolstad, W. M. and Curran, J. M. (2016), [Introduction to Bayesian Statistics](https://doi.org/10.1002/9781118593165) , Third Edition. John Wiley and Sons, Inc. - `r pkg("car")`, `r pkg("carData")`, `r pkg("effects")`: Fox, J, and Weisberg, S. (2019), [An R Companion to Applied Regression](https://uk.sagepub.com/en-gb/eur/an-r-companion-to-applied-regression/book246125) , Springer Verlag, New York. [Further resources](https://socialsciences.mcmaster.ca/jfox/Books/Companion/index.html) . - `r pkg("CatDataAnalysis")`: Agresti, A. (2013), [Categorical Data Analysis](https://www.wiley.com/en-gb/Categorical+Data+Analysis%2C+3rd+Edition-p-9780470463635), Third Edition, John Wiley and Sons, Inc. - `r pkg("faraway")`: Three books by Julian Faraway: [Practical Regression and ANOVA in R](https://cran.r-project.org/doc/contrib/Faraway-PRA.pdf) (CRAN document), [Linear Models with R](https://www.crcpress.com/Linear-Models-with-R-Second-Edition/Faraway/p/book/9781439887332) (2014), CRC Press, [Extending the Linear Model with R](https://www.crcpress.com/Extending-the-Linear-Model-with-R-Generalized-Linear-Mixed-Effects-and/Faraway/p/book/9781498720960) (2016), CRC Press. - `r pkg("HH")`: Heiberger, R. M. and Holland B. (2015), [Statistical Analysis and Data Display: An Intermediate Course with Examples in R](https://doi.org/10.1007/978-1-4939-2122-5) , Second edition. Springer-Verlag, New York. - `r pkg("HKRbook")`: Härdle, W. K., Klinke, S. and Rönz, B. (2015), [Introduction to Statistics](https://doi.org/10.1007%2F978-3-319-17704-5). Springer Verlag, New York. [Further resources](https://extras.springer.com/?query=978-3-319-17703-8). - `r pkg("HRW")`: Harezlak J., Ruppert D., and Wand M. P. (2018), [Semiparametric Regression with R](https://doi.org/10.1007/978-1-4939-8853-2). Springer Verlag, New York. [Further resources](http://www.semiparametric-regression-with-r.net/). - `r pkg("HSAUR3")`: Hothorn, T. and Everitt, B. S. (2014), [A Handbook of Statistical Analyses using R](https://www.crcpress.com/A-Handbook-of-Statistical-Analyses-using-R-Third-Edition/Hothorn-Everitt/p/book/9781482204582) , Third Edition. New York: Chapman and Hall/CRC. - `r pkg("ISwR")`: Dalgaard, P. (2008), [Introductory Statistics with R](https://doi.org/10.1007/978-0-387-79054-1) , Second Edition, Springer Verlag, New York. - `r pkg("MASS", priority = "core")`: Venables, W. N. and Ripley, B. D. (2002) [Modern Applied Statistics with S](https://www.springer.com/gb/book/9780387954578) , Fourth Edition, Springer, New York. [Further resources](http://www.stats.ox.ac.uk/pub/MASS4). - `r pkg("moderndive")`: Ismay, C. and Kim, A. Y. (2019) [ModernDive: Statistical Inference via Data Science](https://moderndive.com/) . See also `r pkg("infer")`. - `r pkg("MPV")`: Montgomery, D.C., Peck, E. A. and Vining, G. (2012), [Introduction to Linear Regression Analysis](https://www.wiley.com/en-gb/Introduction+to+Linear+Regression+Analysis%2C+6th+Edition-p-00029190) , John Wiley and Sons, Inc. - `r pkg("msos")`: Marden, J. (2015) [Multivariate Statistics: Old School](%20http://istics.net/stat/Multivariate/) , CreateSpace Independent Publishing Platform. [Free PDF version](http://istics.net/pdfs/multivariate.pdf). - `r pkg("openintro")`: Open-source textbooks and resources for introductory statistics published by [OpenIntro](https://www.openintro.org/). - `r pkg("regtools")`: Matloff, N. (2017), [Statistical Regression and Classification: from Linear Models to Machine Learning](https://www.crcpress.com/Statistical-Regression-and-Classification-From-Linear-Models-to-Machine/Matloff/p/book/9781498710916) , New York: Chapman and Hall/CRC. - `r pkg("resampledata")`: Chihara, L. M. and Hesterberg, T. C. (2018), [Mathematical Statistics with Resampling in R](https://www.wiley.com/en-us/Mathematical+Statistics+with+Resampling+and+R%2C+2nd+Edition-p-9781119416531) , Second Edition, John Wiley and Sons, Inc. [Further resources](https://sites.google.com/site/chiharahesterberg/). - `r pkg("Sleuth2")` and `r pkg("Sleuth3")`: Ramsey, F. and Schafer, D. (2013), [The Statistical Sleuth: a Course in Methods of Data Analysis](http://www.statisticalsleuth.com/) , Brooks / Cole Cengage Learning. - `r pkg("SMPracticals")`: Davison, A. C. (2003), [Statistical Models](https://doi.org/10.1017/CBO9780511815850) , Cambridge University Press. [Further resources](http://statwww.epfl.ch/davison/SM/). - `r pkg("vcd")`, `r pkg("vcdExtra")`: Friendly, M. and Meyer, D. (2015), [Discrete Data Analysis with R](https://www.crcpress.com/Discrete-Data-Analysis-with-R-Visualization-and-Modeling-Techniques-for/Friendly-Meyer/p/book/9781498725835) , New York: Chapman and Hall/CRC. [Further resources](http://ddar.datavis.ca/). - `r pkg("wooldridge")`: Wooldridge, J. M. (2016), [Introductory Econometrics: A Modern Approach](https://www.cengage.uk/shop/isbn/9781337558860) , Seventh edition, CENGAGE Learning Custom Publishing. ### Links - [Mailing list: R Special Interest Group on Teaching Statistics using R](https://stat.ethz.ch/mailman/listinfo/r-sig-teaching) - [ABC News' FiveThirtyEight: opinion poll, politics, economics and sports datasets, blogs and some R code.](https://data.fivethirtyeight.com/) - [The fivethirtyeight package: unofficial collection of datasets and code from FiveThirtyEight.](https://CRAN.R-project.org/package=fivethirtyeight) - [R/exams homepage](http://www.R-exams.org/) - [OpenIntro text books and R Labs](https://www.openintro.org/) - [Project MOSAIC homepage](http://mosaic-web.org/) - [The R Commander homepage](https://socialsciences.mcmaster.ca/jfox/Misc/Rcmdr/) - [The swirl home page](https://swirlstats.com/)