January 19, 2017

Tidyverse

Core Packages

  • ggplot2 (graphics)
  • tibble (data frames and tables)
  • tidyr (make tidy)
  • readr (read in formats)
  • purrr (functional programming)
  • dplyr (manipulate data)

Tidyverse (All)

Part 1

  • broom
  • DBI
  • dplyr (H, RStudio)
  • forcats (H, RStudio)
  • ggplot2 (H, RStudio)
  • haven (H, RStudio)
  • httr (H, RStudio)
  • hms
  • jsonlite
  • lubridate (H)

Part 2

  • magrittr (H)
  • modelr (H, RStudio)
  • purrr (H, RStudio)
  • readr (H, RStudio)
  • readxl (H, RStudio)
  • stringr (H, RStudio)
  • tibble (H, RStudio)
  • rvest (H, RStudio)
  • tidyr (H, RStudio)
  • xml2 (H, RStudio)

R for Data Science

Make R functions purrr with functional programming

Goal:

"…allow you to break common list manipulation challenges into independent pieces."

Functional Programming

In computer science, functional programming is a programming paradigm—a style of building the structure and elements of computer programs—that treats computation as the evaluation of mathematical functions and avoids changing-state and mutable data.

Overview of Functional

General Format

map(.x, .f, ...)
map(VECTOR_OR_LIST_INPUT, FUNCTION_TO_APPLY, OPTIONAL_OTHER_STUFF)

Questions?

Resources