Package: sdamr 0.2.0

sdamr: Statistics: Data Analysis and Modelling

Data sets and functions to support the books "Statistics: Data analysis and modelling" by Speekenbrink, M. (2021) <https://mspeekenbrink.github.io/sdam-book/> and "An R companion to Statistics: data analysis and modelling" by Speekenbrink, M. (2021) <https://mspeekenbrink.github.io/sdam-r-companion/>. All datasets analysed in these books are provided in this package. In addition, the package provides functions to compute sample statistics (variance, standard deviation, mode), create raincloud and enhanced Q-Q plots, and expand Anova results into omnibus tests and tests of individual contrasts.

Authors:Maarten Speekenbrink [aut, cre]

sdamr_0.2.0.tar.gz
sdamr_0.2.0.zip(r-4.5)sdamr_0.2.0.zip(r-4.4)sdamr_0.2.0.zip(r-4.3)
sdamr_0.2.0.tgz(r-4.4-any)sdamr_0.2.0.tgz(r-4.3-any)
sdamr_0.2.0.tar.gz(r-4.5-noble)sdamr_0.2.0.tar.gz(r-4.4-noble)
sdamr_0.2.0.tgz(r-4.4-emscripten)sdamr_0.2.0.tgz(r-4.3-emscripten)
sdamr.pdf |sdamr.html
sdamr/json (API)
NEWS

# Install 'sdamr' in R:
install.packages('sdamr', repos = c('https://mspeekenbrink.r-universe.dev', 'https://cloud.r-project.org'))

Peer review:

Bug tracker:https://github.com/mspeekenbrink/sdam-r/issues

Datasets:
  • anchoring - Anchoring
  • cheerleader - Data from Experiment 1 of Carragher, D.J., Thomas, N.A., Gwinn, O.S. et al. (2019) Limited evidence of hierarchical encoding in the cheerleader effect. Scientific Reports, 9, 9329. https://doi.org/10.1038/s41598-019-45789-6
  • expBelief - Data from Experiment 5 of Gilder, T. S. E., & Heerey, E. A. (2018). The Role of Experimenter Belief in Social Priming. Psychological Science, 29(3), 403–417.
  • fifa2010 - Predictions by Paul the Octopus in the 2010 FIFA World Cup.
  • fifa2010teams - FIFA 2010 team statistics
  • gestures - Data from Winter, B., & Burkner, P. (2021) Poisson regression for linguists: A tutorial introduction to modelling count data with brms. Language and Linguistics Compass, 15, e12439 doi:10.1111/lnc3.12439 <https://doi.org/10.1111/lnc3.12439>
  • legacy2015 - Legacy motives and pro-environmental behaviour
  • metacognition - Data from Rausch, M. & Zehetleitner, M. (2016) Visibility is not equivalent to confidence in a low contrast orientation discrimination task. Frontiers in Psychology, 7, p. 591 doi:10.3389/fpsyg.2016.00591 <https://doi.org/10.3389/fpsyg.2016.00591>
  • papervotes - Data based on a post-election survey by YouGov (see <https://yougov.co.uk/topics/politics/articles-reports/2017/06/13/how-britain-voted-2017-general-election>). Note that the data was recreated by combining frequency and percentage results reported in <https://d25d2506sfb94s.cloudfront.net/cumulus_uploads/document/smo1w49ph1/InternalResults_170613_2017Election_Demographics_W.pdf>. Due to rounding and other potential inconsistencies, this data set will likely differ from the actual results.
  • redist2015 - Redistribution of wealth
  • rps - Data from Experiment 1 in Guennouni, I., Speekenbrink, M. (2022). Transfer of learned opponent models in repeated games. Computational Brain and Behaviour, 5, 326–342 doi:10.1007/s42113-022-00133-6 <https://doi.org/10.1007/s42113-022-00133-6>. Participants (n=52) each play 50 rounds of Rock-Paper-Scissors against an AI player who either adopts a "level-1" or "level-2" strategy. A level-1 strategy assumes the opponent will repeat their last action, and chooses the action that beats this. A level-2 strategy assumes the opponent adopts a level-1 strategy, and chooses the action that beats this. On 10% of rounds, the AI players pick a random action. On the remainder, they act according to their strategy.
  • speeddate - Speed dating
  • tetris2015 - Tetris and intrusive memories
  • trump2016 - Trump votes in 2016 for 50 US states and the District of Columbia
  • uefa2008 - Predictions by Paul the Octopus in the 2008 UEFA Cup.

On CRAN:

4.28 score 4 stars 96 scripts 329 downloads 11 exports 60 dependencies

Last updated 2 years agofrom:d637c71b13. Checks:OK: 1 NOTE: 6. Indexed: yes.

TargetResultDate
Doc / VignettesOKNov 02 2024
R-4.5-winNOTENov 02 2024
R-4.5-linuxNOTENov 02 2024
R-4.4-winNOTENov 02 2024
R-4.4-macNOTENov 02 2024
R-4.3-winNOTENov 02 2024
R-4.3-macNOTENov 02 2024

Exports:centerexpand_Anovageom_flat_violinGeomFlatViolinplot_qq_marginalsplot_raincloudposition_jitternudgePositionJitternudgesample_modesample_sdsample_var

Dependencies:abindbackportsbootbroomcarcarDataclicolorspacecowplotcpp11DerivdoBydplyrfansifarverFormulagenericsggplot2gluegtableisobandlabelinglatticelifecyclelme4magrittrMASSMatrixMatrixModelsmgcvmicrobenchmarkminqamodelrmunsellnlmenloptrnnetnumDerivpbkrtestpillarpkgconfigpurrrquantregR6RColorBrewerRcppRcppEigenrlangscalesSparseMstringistringrsurvivaltibbletidyrtidyselectutf8vctrsviridisLitewithr

Readme and manuals

Help Manual

Help pageTopics
Anchoringanchoring
Mean-centered valuescenter
Data from Experiment 1 of Carragher, D.J., Thomas, N.A., Gwinn, O.S. et al. (2019) Limited evidence of hierarchical encoding in the cheerleader effect. Scientific Reports, 9, 9329. https://doi.org/10.1038/s41598-019-45789-6cheerleader
Expand all contrast terms in car::Anovaexpand_Anova
Data from Experiment 5 of Gilder, T. S. E., & Heerey, E. A. (2018). The Role of Experimenter Belief in Social Priming. Psychological Science, 29(3), 403–417.expBelief
Predictions by Paul the Octopus in the 2010 FIFA World Cup.fifa2010
FIFA 2010 team statisticsfifa2010teams
Half violin plotgeom_flat_violin
Flat violin geometryGeomFlatViolin PositionJitternudge
Data from Winter, B., & Burkner, P. (2021) Poisson regression for linguists: A tutorial introduction to modelling count data with brms. Language and Linguistics Compass, 15, e12439 doi:10.1111/lnc3.12439 <https://doi.org/10.1111/lnc3.12439>gestures
Legacy motives and pro-environmental behaviourlegacy2015
Data from Rausch, M. & Zehetleitner, M. (2016) Visibility is not equivalent to confidence in a low contrast orientation discrimination task. Frontiers in Psychology, 7, p. 591 doi:10.3389/fpsyg.2016.00591 <https://doi.org/10.3389/fpsyg.2016.00591>metacognition
Data based on a post-election survey by YouGov (see <https://yougov.co.uk/topics/politics/articles-reports/2017/06/13/how-britain-voted-2017-general-election>). Note that the data was recreated by combining frequency and percentage results reported in <https://d25d2506sfb94s.cloudfront.net/cumulus_uploads/document/smo1w49ph1/InternalResults_170613_2017Election_Demographics_W.pdf>. Due to rounding and other potential inconsistencies, this data set will likely differ from the actual results.papervotes
Q-Q plots with distributions in the marginsplot_qq_marginals
Create a raincloud plotplot_raincloud
Simultaneously nudge and jitterposition_jitternudge
Redistribution of wealthredist2015
Data from Experiment 1 in Guennouni, I., Speekenbrink, M. (2022). Transfer of learned opponent models in repeated games. Computational Brain and Behaviour, 5, 326–342 doi:10.1007/s42113-022-00133-6 <https://doi.org/10.1007/s42113-022-00133-6>. Participants (n=52) each play 50 rounds of Rock-Paper-Scissors against an AI player who either adopts a "level-1" or "level-2" strategy. A level-1 strategy assumes the opponent will repeat their last action, and chooses the action that beats this. A level-2 strategy assumes the opponent adopts a level-1 strategy, and chooses the action that beats this. On 10% of rounds, the AI players pick a random action. On the remainder, they act according to their strategy.rps
Compute a sample modesample_mode
Compute the sample standard deviationsample_sd
Compute the sample variancesample_var
Speed datingspeeddate
Tetris and intrusive memoriestetris2015
Trump votes in 2016 for 50 US states and the District of Columbiatrump2016
Predictions by Paul the Octopus in the 2008 UEFA Cup.uefa2008