| YaRrr! The Pirate's Guide to R | https://bookdown.org/ndphillips/YaRrr/ |
| 1 Preface | https://bookdown.org/ndphillips/YaRrr/index.html |
| 1.1 Where did this book come from? | https://bookdown.org/ndphillips/YaRrr/where-did-this-book-come-from.html |
| 1.2 Who is this book for? | https://bookdown.org/ndphillips/YaRrr/who-is-this-book-for.html |
| 1.3 Why is R so great? | https://bookdown.org/ndphillips/YaRrr/why-is-r-so-great.html |
| 1.4 Why R is like a relationship… | https://bookdown.org/ndphillips/YaRrr/rrelationship.html |
| 1.5 R resources | https://bookdown.org/ndphillips/YaRrr/r-resources.html |
| 1.5.1 R Cheatsheets | https://bookdown.org/ndphillips/YaRrr/r-resources.html#r-cheatsheets |
| 1.5.2 Getting R help and inspiration online | https://bookdown.org/ndphillips/YaRrr/r-resources.html#getting-r-help-and-inspiration-online |
| 1.5.3 Other R books | https://bookdown.org/ndphillips/YaRrr/r-resources.html#other-r-books |
| 1.6 Who am I? | https://bookdown.org/ndphillips/YaRrr/who-am-i.html |
| 1.6.1 Please consider a donation! | https://bookdown.org/ndphillips/YaRrr/who-am-i.html#please-consider-a-donation |
| 1.6.2 Acknowledgements | https://bookdown.org/ndphillips/YaRrr/who-am-i.html#acknowledgements |
| 1.7 Contributions and Acknowledgements | https://bookdown.org/ndphillips/YaRrr/contributions-and-acknowledgements.html |
| 2 Getting Started | https://bookdown.org/ndphillips/YaRrr/started.html |
| 2.1 Installing Base-R and RStudio | https://bookdown.org/ndphillips/YaRrr/installing-base-r-and-rstudio.html |
| 2.1.1 Check for version updates | https://bookdown.org/ndphillips/YaRrr/installing-base-r-and-rstudio.html#check-for-version-updates |
| 2.2 The four RStudio Windows | https://bookdown.org/ndphillips/YaRrr/the-four-rstudio-windows.html |
| 2.2.1 Source - Your notepad for code | https://bookdown.org/ndphillips/YaRrr/the-four-rstudio-windows.html#source---your-notepad-for-code |
| 2.2.2 Console: R’s Heart | https://bookdown.org/ndphillips/YaRrr/the-four-rstudio-windows.html#console-rs-heart |
| 2.2.3 Environment / History | https://bookdown.org/ndphillips/YaRrr/the-four-rstudio-windows.html#environment-history |
| 2.2.4 Files / Plots / Packages / Help | https://bookdown.org/ndphillips/YaRrr/the-four-rstudio-windows.html#files-plots-packages-help |
| 2.3 Packages | https://bookdown.org/ndphillips/YaRrr/packages.html |
| 2.3.1 Installing a new package | https://bookdown.org/ndphillips/YaRrr/packages.html#installing-a-new-package |
| 2.3.2 Loading a package | https://bookdown.org/ndphillips/YaRrr/packages.html#loading-a-package |
| 2.4 Reading and writing Code | https://bookdown.org/ndphillips/YaRrr/reading-and-writing-code.html |
| 2.4.1 Code Chunks | https://bookdown.org/ndphillips/YaRrr/reading-and-writing-code.html#code-chunks |
| 2.4.2 Comments with # | https://bookdown.org/ndphillips/YaRrr/reading-and-writing-code.html#comments-with |
| 2.4.3 Element numbers in output [1] | https://bookdown.org/ndphillips/YaRrr/reading-and-writing-code.html#element-numbers-in-output-1 |
| 2.5 Debugging | https://bookdown.org/ndphillips/YaRrr/debugging.html |
| 2.5.1 R is not ready (>) | https://bookdown.org/ndphillips/YaRrr/debugging.html#r-is-not-ready |
| 2.5.2 Misspelled object or function | https://bookdown.org/ndphillips/YaRrr/debugging.html#misspelled-object-or-function |
| 2.5.3 Punctuation problems | https://bookdown.org/ndphillips/YaRrr/debugging.html#punctuation-problems |
| 3 Jump In! | https://bookdown.org/ndphillips/YaRrr/jumpin.html |
| 3.1 Exploring data | https://bookdown.org/ndphillips/YaRrr/exploring-data.html |
| 3.2 Descriptive statistics | https://bookdown.org/ndphillips/YaRrr/descriptive-statistics.html |
| 3.3 Plotting | https://bookdown.org/ndphillips/YaRrr/plotting.html |
| 3.4 Hypothesis tests | https://bookdown.org/ndphillips/YaRrr/hypothesis-tests.html |
| 3.5 Regression analysis | https://bookdown.org/ndphillips/YaRrr/regression-analysis.html |
| 3.6 Bayesian Statistics | https://bookdown.org/ndphillips/YaRrr/bayesian-statistics.html |
| 3.7 Wasn’t that easy?! | https://bookdown.org/ndphillips/YaRrr/wasnt-that-easy.html |
| 4 The Basics | https://bookdown.org/ndphillips/YaRrr/basics.html |
| 4.1 The command-line (Console) | https://bookdown.org/ndphillips/YaRrr/the-command-line-console.html |
| 4.2 Writing R scripts in an editor | https://bookdown.org/ndphillips/YaRrr/writing-r-scripts-in-an-editor.html |
| 4.2.1 Send code from an source to the console | https://bookdown.org/ndphillips/YaRrr/writing-r-scripts-in-an-editor.html#send-code-from-an-source-to-the-console |
| 4.3 A brief style guide: Commenting and spacing | https://bookdown.org/ndphillips/YaRrr/a-brief-style-guide-commenting-and-spacing.html |
| 4.3.1 Commenting code with the # (pound) sign | https://bookdown.org/ndphillips/YaRrr/a-brief-style-guide-commenting-and-spacing.html#commenting-code-with-the-pound-sign |
| 4.3.2 Spacing | https://bookdown.org/ndphillips/YaRrr/a-brief-style-guide-commenting-and-spacing.html#spacing |
| 4.4 Objects and functions | https://bookdown.org/ndphillips/YaRrr/objects-and-functions.html |
| 4.4.1 Numbers versus characters | https://bookdown.org/ndphillips/YaRrr/objects-and-functions.html#numbers-versus-characters |
| 4.4.2 Creating new objects with <- | https://bookdown.org/ndphillips/YaRrr/objects-and-functions.html#creating-new-objects-with-- |
| 4.4.3 How to name objects | https://bookdown.org/ndphillips/YaRrr/objects-and-functions.html#how-to-name-objects |
| 4.4.4 Example: Pirates of The Caribbean | https://bookdown.org/ndphillips/YaRrr/objects-and-functions.html#example-pirates-of-the-caribbean |
| 4.5 Test your R might! | https://bookdown.org/ndphillips/YaRrr/test-your-r-might.html |
| 5 Scalars and vectors | https://bookdown.org/ndphillips/YaRrr/scalersvectors.html |
| 5.1 Scalars | https://bookdown.org/ndphillips/YaRrr/scalars.html |
| 5.2 Vectors | https://bookdown.org/ndphillips/YaRrr/vectors.html |
| 5.2.1 a:b | https://bookdown.org/ndphillips/YaRrr/vectors.html#ab |
| 5.2.2 seq() | https://bookdown.org/ndphillips/YaRrr/vectors.html#seq |
| 5.2.3 rep() | https://bookdown.org/ndphillips/YaRrr/vectors.html#rep |
| 5.3 Generating random data | https://bookdown.org/ndphillips/YaRrr/generating-random-data.html |
| 5.3.1 sample() | https://bookdown.org/ndphillips/YaRrr/generating-random-data.html#sample |
| 5.3.2 Normal (Gaussian) | https://bookdown.org/ndphillips/YaRrr/generating-random-data.html#normal-gaussian |
| 5.3.3 Uniform | https://bookdown.org/ndphillips/YaRrr/generating-random-data.html#uniform |
| 5.3.4 Notes on random samples | https://bookdown.org/ndphillips/YaRrr/generating-random-data.html#notes-on-random-samples |
| 5.4 Test your R might! | https://bookdown.org/ndphillips/YaRrr/test-your-r-might-1.html |
| 6 Vector functions | https://bookdown.org/ndphillips/YaRrr/vectorfunctions.html |
| 6.1 Arithmetic operations on vectors | https://bookdown.org/ndphillips/YaRrr/arithmetic-operations-on-vectors.html |
| 6.1.1 Basic math with multiple vectors | https://bookdown.org/ndphillips/YaRrr/arithmetic-operations-on-vectors.html#basic-math-with-multiple-vectors |
| 6.1.2 Ex: Pirate Bake Sale | https://bookdown.org/ndphillips/YaRrr/arithmetic-operations-on-vectors.html#ex-pirate-bake-sale |
| 6.2 Summary statistics | https://bookdown.org/ndphillips/YaRrr/summary-statistics.html |
| 6.2.1 length() | https://bookdown.org/ndphillips/YaRrr/summary-statistics.html#length |
| 6.2.2 Additional numeric vector functions | https://bookdown.org/ndphillips/YaRrr/summary-statistics.html#additional-numeric-vector-functions |
| 6.2.3 Sample statistics from random samples | https://bookdown.org/ndphillips/YaRrr/summary-statistics.html#sample-statistics-from-random-samples |
| 6.3 Counting statistics | https://bookdown.org/ndphillips/YaRrr/counting-statistics.html |
| 6.4 Missing (NA) values | https://bookdown.org/ndphillips/YaRrr/missing-na-values.html |
| 6.5 Standardization (z-score) | https://bookdown.org/ndphillips/YaRrr/standardization-z-score.html |
| 6.5.1 Ex: Evaluating a competition | https://bookdown.org/ndphillips/YaRrr/standardization-z-score.html#ex-evaluating-a-competition |
| 6.6 Test your R Might! | https://bookdown.org/ndphillips/YaRrr/test-your-r-might-2.html |
| 7 Indexing Vectors with [ ] | https://bookdown.org/ndphillips/YaRrr/vectorindexing.html |
| 7.1 Numerical Indexing | https://bookdown.org/ndphillips/YaRrr/numerical-indexing.html |
| 7.2 Logical Indexing | https://bookdown.org/ndphillips/YaRrr/logical-indexing.html |
| 7.2.1 & (and), | (or), %in% | https://bookdown.org/ndphillips/YaRrr/logical-indexing.html#and-or-in |
| 7.2.2 Counts and percentages from logical vectors | https://bookdown.org/ndphillips/YaRrr/logical-indexing.html#counts-and-percentages-from-logical-vectors |
| 7.2.3 Additional Logical functions | https://bookdown.org/ndphillips/YaRrr/logical-indexing.html#additional-logical-functions |
| 7.3 Changing values of a vector | https://bookdown.org/ndphillips/YaRrr/changing-values-of-a-vector.html |
| 7.3.1 Ex: Fixing invalid responses to a Happiness survey | https://bookdown.org/ndphillips/YaRrr/changing-values-of-a-vector.html#ex-fixing-invalid-responses-to-a-happiness-survey |
| 7.4 Test your R Might!: Movie data | https://bookdown.org/ndphillips/YaRrr/test-your-r-might-movie-data.html |
| 8 Matrices and Dataframes | https://bookdown.org/ndphillips/YaRrr/matricesdataframes.html |
| 8.1 What are matrices and dataframes? | https://bookdown.org/ndphillips/YaRrr/what-are-matrices-and-dataframes.html |
| 8.2 Creating matrices and dataframes | https://bookdown.org/ndphillips/YaRrr/creating-matrices-and-dataframes.html |
| 8.2.1 cbind(), rbind() | https://bookdown.org/ndphillips/YaRrr/creating-matrices-and-dataframes.html#cbind-rbind |
| 8.2.2 matrix() | https://bookdown.org/ndphillips/YaRrr/creating-matrices-and-dataframes.html#matrix |
| 8.2.3 data.frame() | https://bookdown.org/ndphillips/YaRrr/creating-matrices-and-dataframes.html#data.frame |
| 8.2.4 Dataframes pre-loaded in R | https://bookdown.org/ndphillips/YaRrr/creating-matrices-and-dataframes.html#dataframes-pre-loaded-in-r |
| 8.3 Matrix and dataframe functions | https://bookdown.org/ndphillips/YaRrr/matrix-and-dataframe-functions.html |
| 8.3.1 head(), tail(), View() | https://bookdown.org/ndphillips/YaRrr/matrix-and-dataframe-functions.html#head-tail-view |
| 8.3.2 summary(), str() | https://bookdown.org/ndphillips/YaRrr/matrix-and-dataframe-functions.html#summary-str |
| 8.4 Dataframe column names | https://bookdown.org/ndphillips/YaRrr/dataframe-column-names.html |
| 8.4.1 Adding new columns | https://bookdown.org/ndphillips/YaRrr/dataframe-column-names.html#adding-new-columns |
| 8.4.2 Changing column names | https://bookdown.org/ndphillips/YaRrr/dataframe-column-names.html#changing-column-names |
| 8.5 Slicing dataframes | https://bookdown.org/ndphillips/YaRrr/slicing-dataframes.html |
| 8.5.1 Slicing with [, ] | https://bookdown.org/ndphillips/YaRrr/slicing-dataframes.html#slicing-with |
| 8.5.2 Slicing with logical vectors | https://bookdown.org/ndphillips/YaRrr/slicing-dataframes.html#slicing-with-logical-vectors |
| 8.5.3 Slicing with subset() | https://bookdown.org/ndphillips/YaRrr/slicing-dataframes.html#slicing-with-subset |
| 8.6 Combining slicing with functions | https://bookdown.org/ndphillips/YaRrr/combining-slicing-with-functions.html |
| 8.6.1 with() | https://bookdown.org/ndphillips/YaRrr/combining-slicing-with-functions.html#with |
| 8.7 Test your R might! Pirates and superheroes | https://bookdown.org/ndphillips/YaRrr/test-your-r-might-pirates-and-superheroes.html |
| 9 Importing, saving and managing data | https://bookdown.org/ndphillips/YaRrr/importingdata.html |
| 9.1 Workspace management functions | https://bookdown.org/ndphillips/YaRrr/workspace-management-functions.html |
| 9.1.1 Why object and file management is so important | https://bookdown.org/ndphillips/YaRrr/workspace-management-functions.html#why-object-and-file-management-is-so-important |
| 9.2 The working directory | https://bookdown.org/ndphillips/YaRrr/the-working-directory.html |
| 9.3 Projects in RStudio | https://bookdown.org/ndphillips/YaRrr/projects-in-rstudio.html |
| 9.4 The workspace | https://bookdown.org/ndphillips/YaRrr/the-workspace.html |
| 9.4.1 ls() | https://bookdown.org/ndphillips/YaRrr/the-workspace.html#ls |
| 9.5 .RData files | https://bookdown.org/ndphillips/YaRrr/rdata-files.html |
| 9.5.1 save() | https://bookdown.org/ndphillips/YaRrr/rdata-files.html#save |
| 9.5.2 save.image() | https://bookdown.org/ndphillips/YaRrr/rdata-files.html#save.image |
| 9.5.3 load() | https://bookdown.org/ndphillips/YaRrr/rdata-files.html#load |
| 9.5.4 rm() | https://bookdown.org/ndphillips/YaRrr/rdata-files.html#rm |
| 9.6 .txt files | https://bookdown.org/ndphillips/YaRrr/txt-files.html |
| 9.6.1 write.table() | https://bookdown.org/ndphillips/YaRrr/txt-files.html#write.table |
| 9.6.2 read.table() | https://bookdown.org/ndphillips/YaRrr/txt-files.html#read.table |
| 9.6.3 Reading files directly from a web URL | https://bookdown.org/ndphillips/YaRrr/txt-files.html#reading-files-directly-from-a-web-url |
| 9.7 Excel, SPSS, and other data files | https://bookdown.org/ndphillips/YaRrr/excel-spss-and-other-data-files.html |
| 9.8 Additional tips | https://bookdown.org/ndphillips/YaRrr/additional-tips.html |
| 9.9 Test your R Might! | https://bookdown.org/ndphillips/YaRrr/test-your-r-might-3.html |
| 10 Advanced dataframe manipulation | https://bookdown.org/ndphillips/YaRrr/advanceddataframe.html |
| 10.1 order(): Sorting data | https://bookdown.org/ndphillips/YaRrr/order-sorting-data.html |
| 10.2 merge(): Combining data | https://bookdown.org/ndphillips/YaRrr/merge-combining-data.html |
| 10.3 aggregate(): Grouped aggregation | https://bookdown.org/ndphillips/YaRrr/aggregate-grouped-aggregation.html |
| 10.4 dplyr | https://bookdown.org/ndphillips/YaRrr/dplyr.html |
| 10.4.1 Additional dplyr help | https://bookdown.org/ndphillips/YaRrr/dplyr.html#additional-dplyr-help |
| 10.5 Additional aggregation functions | https://bookdown.org/ndphillips/YaRrr/additional-aggregation-functions.html |
| 10.5.1 rowMeans(), colMeans() | https://bookdown.org/ndphillips/YaRrr/additional-aggregation-functions.html#rowmeans-colmeans |
| 10.5.2 apply family | https://bookdown.org/ndphillips/YaRrr/additional-aggregation-functions.html#apply-family |
| 10.6 Test your R might!: Mmmmm…caffeine | https://bookdown.org/ndphillips/YaRrr/test-your-r-might-mmmmmcaffeine.html |
| 11 Plotting (I) | https://bookdown.org/ndphillips/YaRrr/plotting1.html |
| 11.1 Colors | https://bookdown.org/ndphillips/YaRrr/colors.html |
| 11.1.1 Colors by name | https://bookdown.org/ndphillips/YaRrr/colors.html#colors-by-name |
| 11.1.2 gray() | https://bookdown.org/ndphillips/YaRrr/colors.html#gray |
| 11.1.3 yarrr::transparent() | https://bookdown.org/ndphillips/YaRrr/colors.html#yarrrtransparent |
| 11.2 Plotting arguments | https://bookdown.org/ndphillips/YaRrr/plotting-arguments.html |
| 11.3 Scatterplot: plot() | https://bookdown.org/ndphillips/YaRrr/scatterplot-plot.html |
| 11.3.1 Symbol types: pch | https://bookdown.org/ndphillips/YaRrr/scatterplot-plot.html#symbol-types-pch |
| 11.4 Histogram: hist() | https://bookdown.org/ndphillips/YaRrr/histogram-hist.html |
| 11.5 Barplot: barplot() | https://bookdown.org/ndphillips/YaRrr/barplot-barplot.html |
| 11.5.1 Clustered barplot | https://bookdown.org/ndphillips/YaRrr/barplot-barplot.html#clustered-barplot |
| 11.6 pirateplot() | https://bookdown.org/ndphillips/YaRrr/pirateplot.html |
| 11.6.1 Pirateplot themes | https://bookdown.org/ndphillips/YaRrr/pirateplot.html#pirateplot-themes |
| 11.6.2 Customizing pirateplots | https://bookdown.org/ndphillips/YaRrr/pirateplot.html#customizing-pirateplots |
| 11.6.3 Saving output | https://bookdown.org/ndphillips/YaRrr/pirateplot.html#saving-output |
| 11.7 Low-level plotting functions | https://bookdown.org/ndphillips/YaRrr/low-level-plotting-functions.html |
| 11.7.1 Starting with a blank plot | https://bookdown.org/ndphillips/YaRrr/low-level-plotting-functions.html#starting-with-a-blank-plot |
| 11.7.2 points() | https://bookdown.org/ndphillips/YaRrr/low-level-plotting-functions.html#points |
| 11.7.3 abline(), segments(), grid() | https://bookdown.org/ndphillips/YaRrr/low-level-plotting-functions.html#abline-segments-grid |
| 11.7.4 text() | https://bookdown.org/ndphillips/YaRrr/low-level-plotting-functions.html#text |
| 11.7.5 Combining text and numbers with paste() | https://bookdown.org/ndphillips/YaRrr/low-level-plotting-functions.html#combining-text-and-numbers-with-paste |
| 11.7.6 curve() | https://bookdown.org/ndphillips/YaRrr/low-level-plotting-functions.html#curve |
| 11.7.7 legend() | https://bookdown.org/ndphillips/YaRrr/low-level-plotting-functions.html#legend |
| 11.8 Saving plots to a file with pdf(), jpeg() and png() | https://bookdown.org/ndphillips/YaRrr/saving-plots-to-a-file-with-pdf-jpeg-and-png.html |
| 11.9 Examples | https://bookdown.org/ndphillips/YaRrr/examples.html |
| 11.10 Test your R might! Purdy pictures | https://bookdown.org/ndphillips/YaRrr/test-your-r-might-purdy-pictures.html |
| 12 Plotting (II) | https://bookdown.org/ndphillips/YaRrr/plotting2.html |
| 12.1 More colors | https://bookdown.org/ndphillips/YaRrr/more-colors.html |
| 12.1.1 piratepal() | https://bookdown.org/ndphillips/YaRrr/more-colors.html#piratepal |
| 12.1.2 RColorBrewer | https://bookdown.org/ndphillips/YaRrr/more-colors.html#rcolorbrewer |
| 12.1.3 colorRamp2 | https://bookdown.org/ndphillips/YaRrr/more-colors.html#colorramp2 |
| 12.1.4 Getting colors with a kuler | https://bookdown.org/ndphillips/YaRrr/more-colors.html#getting-colors-with-a-kuler |
| 12.2 Plot Margins | https://bookdown.org/ndphillips/YaRrr/plot-margins.html |
| 12.3 Arranging plots with par(mfrow) and layout() | https://bookdown.org/ndphillips/YaRrr/arranging-plots-with-parmfrow-and-layout.html |
| 12.3.1 Complex plot layouts with layout() | https://bookdown.org/ndphillips/YaRrr/arranging-plots-with-parmfrow-and-layout.html#complex-plot-layouts-with-layout |
| 12.4 Additional plotting parameters | https://bookdown.org/ndphillips/YaRrr/additional-plotting-parameters.html |
| 13 Hypothesis Tests | https://bookdown.org/ndphillips/YaRrr/htests.html |
| 13.1 A short introduction to hypothesis tests | https://bookdown.org/ndphillips/YaRrr/a-short-introduction-to-hypothesis-tests.html |
| 13.1.1 Null v Alternative Hypothesis | https://bookdown.org/ndphillips/YaRrr/a-short-introduction-to-hypothesis-tests.html#null-v-alternative-hypothesis |
| 13.1.2 Descriptive statistics | https://bookdown.org/ndphillips/YaRrr/a-short-introduction-to-hypothesis-tests.html#descriptive-statistics-1 |
| 13.1.3 Test Statistics | https://bookdown.org/ndphillips/YaRrr/a-short-introduction-to-hypothesis-tests.html#test-statistics |
| 13.1.4 p-value | https://bookdown.org/ndphillips/YaRrr/a-short-introduction-to-hypothesis-tests.html#p-value |
| 13.2 Hypothesis test objects: htest | https://bookdown.org/ndphillips/YaRrr/hypothesis-test-objects-htest.html |
| 13.3 T-test: t.test() | https://bookdown.org/ndphillips/YaRrr/t-test-t-test.html |
| 13.3.1 1-sample t-test | https://bookdown.org/ndphillips/YaRrr/t-test-t-test.html#sample-t-test |
| 13.3.2 2-sample t-test | https://bookdown.org/ndphillips/YaRrr/t-test-t-test.html#sample-t-test-1 |
| 13.4 Correlation: cor.test() | https://bookdown.org/ndphillips/YaRrr/correlation-cor-test.html |
| 13.5 Chi-square: chsq.test() | https://bookdown.org/ndphillips/YaRrr/chi-square-chsq-test.html |
| 13.5.1 Getting APA-style conclusions with the apa function | https://bookdown.org/ndphillips/YaRrr/chi-square-chsq-test.html#getting-apa-style-conclusions-with-the-apa-function |
| 13.6 Test your R might! | https://bookdown.org/ndphillips/YaRrr/test-your-r-might-4.html |
| 14 ANOVA | https://bookdown.org/ndphillips/YaRrr/anova.html |
| 14.1 Full-factorial between-subjects ANOVA | https://bookdown.org/ndphillips/YaRrr/full-factorial-between-subjects-anova.html |
| 14.1.1 What does ANOVA stand for? | https://bookdown.org/ndphillips/YaRrr/full-factorial-between-subjects-anova.html#what-does-anova-stand-for |
| 14.2 4 Steps to conduct an ANOVA | https://bookdown.org/ndphillips/YaRrr/steps-to-conduct-an-anova.html |
| 14.3 Ex: One-way ANOVA | https://bookdown.org/ndphillips/YaRrr/ex-one-way-anova.html |
| 14.4 Ex: Two-way ANOVA | https://bookdown.org/ndphillips/YaRrr/ex-two-way-anova.html |
| 14.4.1 ANOVA with interactions | https://bookdown.org/ndphillips/YaRrr/ex-two-way-anova.html#anova-with-interactions |
| 14.5 Type I, Type II, and Type III ANOVAs | https://bookdown.org/ndphillips/YaRrr/type-i-type-ii-and-type-iii-anovas.html |
| 14.6 Getting additional information from ANOVA objects | https://bookdown.org/ndphillips/YaRrr/getting-additional-information-from-anova-objects.html |
| 14.7 Repeated measures ANOVA using the lme4 package | https://bookdown.org/ndphillips/YaRrr/repeated-measures-anova-using-the-lme4-package.html |
| 14.8 Test your R might! | https://bookdown.org/ndphillips/YaRrr/test-your-r-might-5.html |
| 15 Regression | https://bookdown.org/ndphillips/YaRrr/regression.html |
| 15.1 The Linear Model | https://bookdown.org/ndphillips/YaRrr/the-linear-model.html |
| 15.2 Linear regression with lm() | https://bookdown.org/ndphillips/YaRrr/linear-regression-with-lm.html |
| 15.2.1 Estimating the value of diamonds with lm() | https://bookdown.org/ndphillips/YaRrr/linear-regression-with-lm.html#estimating-the-value-of-diamonds-with-lm |
| 15.2.2 Getting model fits with fitted.values | https://bookdown.org/ndphillips/YaRrr/linear-regression-with-lm.html#getting-model-fits-with-fitted.values |
| 15.2.3 Using predict() to predict new data from a model | https://bookdown.org/ndphillips/YaRrr/linear-regression-with-lm.html#using-predict-to-predict-new-data-from-a-model |
| 15.2.4 Including interactions in models: y ~ x1 * x2 | https://bookdown.org/ndphillips/YaRrr/linear-regression-with-lm.html#including-interactions-in-models-y-x1-x2 |
| 15.2.5 Center variables before computing interactions! | https://bookdown.org/ndphillips/YaRrr/linear-regression-with-lm.html#center-variables-before-computing-interactions |
| 15.2.6 Getting an ANOVA from a regression model with aov() | https://bookdown.org/ndphillips/YaRrr/linear-regression-with-lm.html#getting-an-anova-from-a-regression-model-with-aov |
| 15.3 Comparing regression models with anova() | https://bookdown.org/ndphillips/YaRrr/comparing-regression-models-with-anova.html |
| 15.4 Regression on non-Normal data with glm() | https://bookdown.org/ndphillips/YaRrr/regression-on-non-normal-data-with-glm.html |
| 15.5 Logistic regression with glm(family = "binomial" | https://bookdown.org/ndphillips/YaRrr/logistic-regression-with-glmfamily-binomial.html |
| 15.5.1 Adding a regression line to a plot | https://bookdown.org/ndphillips/YaRrr/logistic-regression-with-glmfamily-binomial.html#adding-a-regression-line-to-a-plot |
| 15.5.2 Transforming skewed variables prior to standard regression | https://bookdown.org/ndphillips/YaRrr/logistic-regression-with-glmfamily-binomial.html#transforming-skewed-variables-prior-to-standard-regression |
| 15.6 Test your might! A ship auction | https://bookdown.org/ndphillips/YaRrr/test-your-might-a-ship-auction.html |
| 16 Custom functions | https://bookdown.org/ndphillips/YaRrr/functions.html |
| 16.1 Why would you want to write your own function? | https://bookdown.org/ndphillips/YaRrr/why-would-you-want-to-write-your-own-function.html |
| 16.2 The structure of a custom function | https://bookdown.org/ndphillips/YaRrr/the-structure-of-a-custom-function.html |
| 16.2.1 Creating my.mean() | https://bookdown.org/ndphillips/YaRrr/the-structure-of-a-custom-function.html#creating-my.mean |
| 16.2.2 Specifying multiple inputs | https://bookdown.org/ndphillips/YaRrr/the-structure-of-a-custom-function.html#specifying-multiple-inputs |
| 16.2.3 Including default values for arguments | https://bookdown.org/ndphillips/YaRrr/the-structure-of-a-custom-function.html#including-default-values-for-arguments |
| 16.3 Using if, then statements in functions | https://bookdown.org/ndphillips/YaRrr/using-if-then-statements-in-functions.html |
| 16.4 A worked example: plot.advanced() | https://bookdown.org/ndphillips/YaRrr/a-worked-example-plot-advanced.html |
| 16.4.1 Seeing function code | https://bookdown.org/ndphillips/YaRrr/a-worked-example-plot-advanced.html#seeing-function-code |
| 16.4.2 Using stop() to completely stop a function and print an error | https://bookdown.org/ndphillips/YaRrr/a-worked-example-plot-advanced.html#using-stop-to-completely-stop-a-function-and-print-an-error |
| 16.4.3 Using vectors as arguments | https://bookdown.org/ndphillips/YaRrr/a-worked-example-plot-advanced.html#using-vectors-as-arguments |
| 16.4.4 Storing and loading your functions to and from a function file with source() | https://bookdown.org/ndphillips/YaRrr/a-worked-example-plot-advanced.html#storing-and-loading-your-functions-to-and-from-a-function-file-with-source |
| 16.4.5 Testing functions | https://bookdown.org/ndphillips/YaRrr/a-worked-example-plot-advanced.html#testing-functions |
| 16.4.6 Using ... as a wildcard argument | https://bookdown.org/ndphillips/YaRrr/a-worked-example-plot-advanced.html#using-...-as-a-wildcard-argument |
| 16.5 Test your R might! | https://bookdown.org/ndphillips/YaRrr/test-your-r-might-6.html |
| 17 Loops | https://bookdown.org/ndphillips/YaRrr/loops.html |
| 17.1 What are loops? | https://bookdown.org/ndphillips/YaRrr/what-are-loops.html |
| 17.1.1 Printing numbers from 1 to 100 | https://bookdown.org/ndphillips/YaRrr/what-are-loops.html#printing-numbers-from-1-to-100 |
| 17.1.2 Adding the integers from 1 to 100 | https://bookdown.org/ndphillips/YaRrr/what-are-loops.html#adding-the-integers-from-1-to-100 |
| 17.2 Creating multiple plots with a loop | https://bookdown.org/ndphillips/YaRrr/creating-multiple-plots-with-a-loop.html |
| 17.3 Updating a container object with a loop | https://bookdown.org/ndphillips/YaRrr/updating-a-container-object-with-a-loop.html |
| 17.4 Loops over multiple indices with a design matrix | https://bookdown.org/ndphillips/YaRrr/loops-over-multiple-indices-with-a-design-matrix.html |
| 17.5 The list object | https://bookdown.org/ndphillips/YaRrr/the-list-object.html |
| 17.6 Test your R might! | https://bookdown.org/ndphillips/YaRrr/test-your-r-might-7.html |
| 18 Solutions | https://bookdown.org/ndphillips/YaRrr/solutions.html |
| 18.1 Chapter 4: The Basics | https://bookdown.org/ndphillips/YaRrr/chapter-4-the-basics.html |
| 18.2 Chapter 5: Scalers and vectors | https://bookdown.org/ndphillips/YaRrr/chapter-5-scalers-and-vectors.html |
| 18.3 Chapter 6: Vector Functions | https://bookdown.org/ndphillips/YaRrr/chapter-6-vector-functions.html |
| 18.4 Chapter 7: Indexing vectors with [] | https://bookdown.org/ndphillips/YaRrr/chapter-7-indexing-vectors-with.html |
| 18.5 Chapter 8: Matrices and Dataframes | https://bookdown.org/ndphillips/YaRrr/chapter-8-matrices-and-dataframes.html |
| 18.6 Chapter 13: Hypothesis tests | https://bookdown.org/ndphillips/YaRrr/chapter-13-hypothesis-tests.html |
| 18.7 Chapter 14: ANOVA | https://bookdown.org/ndphillips/YaRrr/chapter-14-anova.html |
| 18.8 Chapter 15: Regression | https://bookdown.org/ndphillips/YaRrr/chapter-15-regression.html |
| References | https://bookdown.org/ndphillips/YaRrr/references.html |
| Published with bookdown | https://github.com/rstudio/bookdown |
| YaRrr! The Pirate’s Guide to R | https://bookdown.org/ndphillips/YaRrr/ |
| https://bookdown.org/ndphillips/YaRrr/hypothesis-test-objects-htest.html |
| https://bookdown.org/ndphillips/YaRrr/correlation-cor-test.html |