[1] "R version 4.5.1 (2025-06-13)"
Sarah Cassie Burnett
September 2, 2025
<- to assign to._, ._+ addition- subtraction* multiplication/ division^ exponentiation (also **)05:00
== equal to!= not equal to<, >, <=, >= comparisons& AND, | OR , ! NOT<-.<-, and the data or value you wish to assign to the object is on the right.print() used to display the contents of objects.05:00
mean() function to calculate the average of a set of numbers.c() to create a vector of numbers.sample().mean() calculates the mean of a set of numbers.median() calculates the median of a set of numbers.sd() calculates the standard deviation of a set of numbers.sum() calculates the sum of a set of numbers.length() calculates the length of a vectormax() and min() calculate the maximum and minimum values of a vectorround() rounds a number to a specified number of decimal placessqrt() calculates the square root of a numberlog() calculates the natural logarithm of a numberexp() calculates the exponential of a numberabs() calculates the absolute value of a numberCheck the built-in R math formulas behave as expected:
exp() of the vector and then take the log() of thatsample of numbers05:00
read_csv() is a functionsample() is a functionreadr is a package that contains the read_csv() functionggplot2 is a package that contains the ggplot() functioninstall.packages() to install packageslibrary() to load packagespak package to install packages from GitHubpak, run install.packages("pak")library() functioninstall.packages() in your R script or Quarto documenttidyverse package in your environmenttidyverse packagepak package05:00