-
Notifications
You must be signed in to change notification settings - Fork 62
/
Copy pathslides-code.R
58 lines (21 loc) · 849 Bytes
/
slides-code.R
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
# Code demonstrated throughout the slides
# Select helper functions and select_ -------------------------------
# Make a students data.frame
# Select students + math grades
# Better yet, using "contains"
# See also: starts_with, ends_with, matches
# Use select_ to select using strings
# Subject of interest (why this matters):
# Summarise -------------------------------
# Compute values of interest
# Reshaping (we won't focus too much on this today) -------------------------------
# Groupby and summarise -------------------------------
# Which student has the highest average?
# Which exam was most difficult?
# Student with highest math grade
# Worst spanish score
# Left joins -------------------------------
# Student majors
# Student contact info
# Join data.frames
# Order matters!