-
Notifications
You must be signed in to change notification settings - Fork 0
/
New_Jersey_SGP_2011.R
52 lines (28 loc) · 1.03 KB
/
New_Jersey_SGP_2011.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
####################################################################
###
### Code to update SGP analyses for New Jersey
###
####################################################################
### Load SGP Package
require(SGP)
### Load data
load("../Data/New_Jersey_Data_LONG_2011.Rdata")
load("../Data/Base_Files/New_Jersey_SGP.Rdata")
### Merge files
New_Jersey_SGP@Data <- as.data.table(rbind.fill(as.data.frame(New_Jersey_Data_LONG_2011), as.data.frame(New_Jersey_SGP@Data)))
### prepareSGP
New_Jersey_SGP <- prepareSGP(New_Jersey_SGP)
save(New_Jersey_SGP, file="../Data/New_Jersey_SGP.Rdata")
### analyzeSGP
New_Jersey_SGP <- analyzeSGP(New_Jersey_SGP,
years=2011,
simulate.sgps=FALSE)
save(New_Jersey_SGP, file="../Data/New_Jersey_SGP.Rdata")
### combineSGP
New_Jersey_SGP <- combineSGP(New_Jersey_SGP,
years=2011)
save(New_Jersey_SGP, file="../Data/New_Jersey_SGP.Rdata")
### summarizeSGP
New_Jersey_SGP <- summarizeSGP(New_Jersey_SGP)
### visualizeSGP
visualizeSGP(New_Jersey_SGP, sgPlot.demo.report=TRUE)