-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathconfig.R
More file actions
30 lines (18 loc) · 984 Bytes
/
config.R
File metadata and controls
30 lines (18 loc) · 984 Bytes
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
# config.R
# Suggested by Lars Vilhuber
# Create a reproducible R sequence by calling this program from every other program in your sequence
# paths
basepath <- rprojroot::find_root(rprojroot::has_file("config.R"))
# Main directories
icpsrpath <- file.path(basepath,"data","ICPSR_13568","DS0002") # local relative path
inputdata <- file.path(basepath,"data","inputdata") # this is where you would read data acquired elsewhere
outputdata <- file.path(basepath,"data","outputdata") # this is where you would write the data you create in this project
results <- file.path(basepath,"tables") # All tables for inclusion in your paper go here
programs <- file.path(basepath,"programs") # All programs (which you might <- file.path(include") are to be found here
for ( dir in list(icpsrpath,inputdata,outputdata,results)){
if (file.exists(dir)){
} else {
dir.create(file.path(dir))
}
}
dtam <- file.path(outputdata,"pumsak.Rds") # Stata PUMS merged data