Skip to content

Commit

Permalink
Add example literature and a example script
Browse files Browse the repository at this point in the history
  • Loading branch information
RohanAlexander committed Jan 4, 2021
1 parent d15ff0b commit 573193a
Show file tree
Hide file tree
Showing 3 changed files with 38 additions and 0 deletions.
2 changes: 2 additions & 0 deletions inputs/data/raw_data.csv
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
first_col, second_col, third_col
some, raw, data
Binary file not shown.
36 changes: 36 additions & 0 deletions scripts/01-data_cleaning.R
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
#### Preamble ####
# Purpose: Clean the survey data downloaded from [...UPDATE ME!!!!!]
# Author: Rohan Alexander [CHANGE THIS TO YOUR NAME!!!!]
# Data: 3 January 2021
# Contact: [email protected] [PROBABLY CHANGE THIS ALSO!!!!]
# License: MIT
# Pre-requisites:
# - Need to have downloaded the ACS data and saved it to inputs/data
# - Don't forget to gitignore it!
# - Change these to yours
# Any other information needed?


#### Workspace setup ####
# Use R Projects, not setwd().
library(haven)
library(tidyverse)
# Read in the raw data.
raw_data <- readr::read_csv("inputs/data/raw_data.csv"
)
# Just keep some variables that may be of interest (change
# this depending on your interests)
names(raw_data)

reduced_data <-
raw_data %>%
select(first_col,
second_col)
rm(raw_data)


#### What's next? ####




0 comments on commit 573193a

Please sign in to comment.