Publications by Kitada Smalley

DataViz: Geometries

21.09.2022

Part I: Review geom_point 0. Basics Recall our work from last class with using geom_point: Load example data library(tidyverse) data("diamonds") str(diamonds) ## tibble [53,940 × 10] (S3: tbl_df/tbl/data.frame) ## $ carat : num [1:53940] 0.23 0.21 0.23 0.29 0.31 0.24 0.24 0.26 0.22 0.23 ... ## $ cut : Ord.factor w/ 5 levels "Fair"<"Good"...

1277 sym R (4044 sym/40 pcs) 26 img

DataViz: Bars

21.09.2022

Content Reference: This lab reference practice problems from “R for Data Science” - Chapter 3: Data Visualisation https://r4ds.had.co.nz/data-visualisation.html In this lab we will discuss and apply: Position Adjustments (for bars) Geometric Objects Example 1: Diamonds First, call the tidyverse package library(tidyverse) The diamonds datas...

2458 sym R (2549 sym/17 pcs) 8 img

DATA151: dplyr Verbs

22.09.2022

Learning Objectives In this session students will learn the basics of working with dplyr verbs from the tidyverse as well as employ the pipe operator %>%. Use the piping operator %>% in your code to improve readability Employ dplyr Verbs filter() count() arrange() group_by and summarise() select() mutate() You will need to start by calling the...

4166 sym R (10866 sym/40 pcs)

DataViz: Sample Solutions

28.09.2022

Useful Packages library(ggplot2) library(dplyr) library(tidyr) library(tidyverse) library(esquisse) library(scales) library(janitor) library(lubridate) library(stringr) Board Games board_games<-readr::read_csv("https://raw.githubusercontent.com/rfordatascience/tidytuesday/master/data/2019/2019-03-12/board_games.csv") ## Rows: 10532 Columns: 22 #...

120 sym R (7748 sym/27 pcs) 4 img

DATA151: Tidyr and Joins

04.10.2022

Learning Objectives In this lesson students will gain more practice with the tidyverse with a particular focus on wrangling the tidyr package. This lesson covers: tidyr Package gather() spread() unite() separate() Joins: left_join, inner_join, right_join Before you start you will need to load the tidyverse library(tidyverse) PART I: tidyr D...

1808 sym R (14956 sym/62 pcs) 7 img

DATA151: Tidyr and Joins

04.10.2022

Learning Objectives In this lesson students will gain more practice with the tidyverse with a particular focus on wrangling the tidyr package. This lesson covers: tidyr Package gather() spread() unite() separate() Joins: left_join, inner_join, right_join Before you start you will need to load the tidyverse library(tidyverse) PART I: tidyr D...

3019 sym R (14571 sym/63 pcs) 7 img

Diamond Drill Solutions

05.10.2022

Diamonds Are Forever Load the package library(tidyverse) Learn about the data data("diamonds") ## INSERT YOUR CODE HERE ## Question 1 Make a new data set that has the average depth and price of the diamonds in the data set. q1<-diamonds%>% summarise(avgD=mean(depth, na.rm=TRUE), avgP=mean(price, na.rm=TRUE)) q1 ## # A tibble: 1...

1236 sym R (3387 sym/21 pcs)

DATA151: Tables and Bars

13.10.2022

Learning Objectives In this lesson students will learn to apply categorical data analysis methods to data sets with fundamentally different structures. Work with cross-tabulated data Work with individual level raw data Create univarite tables to show marginal distributions Create two-way tables to show joint and conditional distributions Create ...

4069 sym R (8061 sym/63 pcs) 19 img

Tables and Bars

17.10.2022

Learning Objectives In this lesson students will learn to apply categorical data analysis methods to data sets with fundamentally different structures. Work with cross-tabulated data Work with individual level raw data Create univarite tables to show marginal distributions Create two-way tables to show joint and conditional distributions Create ...

4133 sym R (8666 sym/71 pcs) 19 img 4 tbl

Recreate: Voter Registration

18.10.2022

Voter Registrations Are Way, Way Down During the Pandemic FiveThirtyEight article (Jun 26, 2020) by Kaleigh Rogers and Nathaniel Rakich The original article can be found at: https://fivethirtyeight.com/features/voter-registrations-are-way-way-down-during-the-pandemic/ Tasks Identify/implement the major geometry (or geometries) used Identify/imp...

934 sym R (704 sym/5 pcs) 1 img