warming up your workspace

R Foundations through Statistics

Begin with R functions, values, variables, choices, loops and vectors. Small numerical tasks lead to a composed peak-and-category summary, preparing you for the later statistical projects.

First functions

  1. A function that returns a value
  2. A function with an input
  3. Two inputs, one formula
  4. Returning text
  5. A two-step calculation

Variables and types

  1. A value with a name
  2. Change a value
  3. Whole numbers and decimals
  4. Turn a decimal into a whole number
  5. A clearly named formula

Making choices

  1. Return a yes or no
  2. if and else return a value
  3. Pick the larger of two
  4. Three-way bands
  5. Combine conditions

Doing it again

  1. Sum 1 to n
  2. Count with a condition
  3. Accumulate by a step
  4. Stop early with return
  5. A loop inside a loop

Vectors and reuse

  1. Read one item from a vector
  2. Find the largest in a vector
  3. One function using another
  4. A multi-input formula
  5. Capstone: summarize and classify

Explore the full field