Publications by Your name here
Apply 12
Import your data data("mtcars") mtcars <- as_tibble(mtcars) data <- read_csv("../00_data/Salaries.csv") ## Rows: 397 Columns: 6 ## ── Column specification ──────────────────────────────────────────────────────── ## Delimiter: "," ...
371 sym Python (7599 sym/37 pcs) 2 img
Code Along 12
Vectors Introduction Vector basics Important types of automic vector Using automic vectors sample(10) + 10 ## [1] 16 18 20 17 11 13 12 19 14 15 1:10 + 1:2 ## [1] 2 4 4 6 6 8 8 10 10 12 1:9 + 1:3 ## [1] 2 4 6 5 7 9 8 10 12 data.frame(a = 1:10, b = 1:2) ## a b ## 1 1 1 ## 2 2 2 ## 3 3 1 ## 4 4 2 ## 5 5 1 ## 6 ...
311 sym Python (2500 sym/51 pcs)
Apply11
Import your data data(flights) flights %>% skimr::skim() Data summary Name Piped data Number of rows 336776 Number of columns 19 _______________________ Column type frequency: character 4 numeric 14 POSIXct 1 ________________________ Group variables None Variable type: character skim_variable n_missing complete_rate min max empty n_u...
529 sym 4 tbl
Code Along 11
Introduction When should you write a function # For reproducible work set.seed(1234) # Create a data frame df <- tibble::tibble( a = rnorm(10), b = rnorm(10), c = rnorm(10), d = rnorm(10) ) # Re-scale each column df$a <- (df$a - min(df$a, na.rm = TRUE)) / (max(df$a, na.rm = TRUE) - min(df$a, na.rm = TRUE)) df$b <- (df$b - ...
288 sym
Apply 10
Import your data data <- read_csv("../00_data/Olympics.csv") ## Rows: 271116 Columns: 15 ## ── Column specification ──────────────────────────────────────────────────────── ## Delimiter: "," ## chr (10): name, sex, team, noc, games...
291 sym 2 img
Code Along 10
Chapter 15 Introduction Creating factors General social survey gss_cat ## # A tibble: 21,483 × 9 ## year marital age race rincome partyid relig denom tvhours ## <int> <fct> <int> <fct> <fct> <fct> <fct> <fct> <int> ## 1 2000 Never married 26 White $8000 to 9999 Ind,near … Prot… Sout...
430 sym 4 img
Code9
Introduction String Basics chac_data <- "I'm hungry." stringr::str_length("I am hungry.") ## [1] 12 stringr::str_c("I", " am", sep = " ;") ## [1] "I ; am" stringr::str_c(c("I", " am"), collapse = "") ## [1] "I am" stringr::str_sort(c("John", "Mary", "Aaron")) ## [1] "Aaron" "John" "Mary" Matching patterns flights %>% glimpse() ## Rows: 336,776...
334 sym
Apply Data 8
1. Import your data Import two related datasets from TidyTuesday Project. sevens <- readr::read_csv('https://raw.githubusercontent.com/rfordatascience/tidytuesday/main/data/2022/2022-05-24/sevens.csv') ## Rows: 7966 Columns: 16 ## ── Column specification ──────────────────────────────...
2066 sym
Code Along 8
Introduction nycflights13 keys Mutating joins Inner join x <- tribble( ~key, ~val_x, 1, "x1", 2, "x2", 3, "x3" ) y <- tribble( ~key, ~val_y, 1, "y1", 2, "y2", 4, "y3" ) inner_join(x, y) ## Joining with `by = join_by(key)` ## # A tibble: 2 × 3 ## key val_x val_y ## <dbl> <chr> <chr> ## 1 ...
204 sym Python (5399 sym/43 pcs)
Apply 7
Import your data disney <- read_csv("../00_data/disney_films.csv") ## Rows: 27 Columns: 5 ## ── Column specification ──────────────────────────────────────────────────────── ## Delimiter: "," ## chr (3): film, release_date, film_ra...
166 sym Python (2695 sym/11 pcs)