-
Notifications
You must be signed in to change notification settings - Fork 0
/
Hawaii_SGP_2021_PART_B.R
87 lines (77 loc) · 3.3 KB
/
Hawaii_SGP_2021_PART_B.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
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
################################################################################
### ###
### SGP STRAIGHT projections for skip year SGP analyses for 2021 ###
### ###
################################################################################
### Load packages
require(SGP)
require(SGPmatrices)
### Load data
load("Data/Hawaii_SGP.Rdata")
### Load configurations
source("SGP_CONFIG/2021/PART_B/READING.R")
source("SGP_CONFIG/2021/PART_B/MATHEMATICS.R")
HI_CONFIG <- c(READING_2021.config, MATHEMATICS_2021.config)
### Parameters
parallel.config <- list(BACKEND="PARALLEL", WORKERS=list(PERCENTILES=4, BASELINE_PERCENTILES=4, PROJECTIONS=4, LAGGED_PROJECTIONS=4, SGP_SCALE_SCORE_TARGETS=4))
### Add Baseline matrices to SGPstateData
SGPstateData <- addBaselineMatrices("HI", "2021")
SGPstateData[["HI"]][["SGP_Configuration"]][["sgp.target.scale.scores.merge"]] <- NULL
# Establish required meta-data for STRAIGHT projection sequences
SGPstateData[["HI"]][["SGP_Configuration"]][["grade.projection.sequence"]] <- list(
READING_GRADE_3=c(3, 4, 5, 6, 7, 8),
READING_GRADE_4=c(3, 4, 5, 6, 7, 8),
READING_GRADE_5=c(3, 4, 5, 6, 7, 8),
READING_GRADE_6=c(3, 4, 5, 6, 7, 8),
READING_GRADE_7=c(3, 4, 5, 6, 7, 8),
READING_GRADE_8=c(3, 4, 5, 6, 7, 8),
MATHEMATICS_GRADE_3=c(3, 4, 5, 6, 7, 8),
MATHEMATICS_GRADE_4=c(3, 4, 5, 6, 7, 8),
MATHEMATICS_GRADE_5=c(3, 4, 5, 6, 7, 8),
MATHEMATICS_GRADE_6=c(3, 4, 5, 6, 7, 8),
MATHEMATICS_GRADE_7=c(3, 4, 5, 6, 7, 8),
MATHEMATICS_GRADE_8=c(3, 4, 5, 6, 7, 8))
SGPstateData[["HI"]][["SGP_Configuration"]][["content_area.projection.sequence"]] <- list(
READING_GRADE_3=rep("READING", 6),
READING_GRADE_4=rep("READING", 6),
READING_GRADE_5=rep("READING", 6),
READING_GRADE_6=rep("READING", 6),
READING_GRADE_7=rep("READING", 6),
READING_GRADE_8=rep("READING", 6),
MATHEMATICS_GRADE_3=rep("MATHEMATICS", 6),
MATHEMATICS_GRADE_4=rep("MATHEMATICS", 6),
MATHEMATICS_GRADE_5=rep("MATHEMATICS", 6),
MATHEMATICS_GRADE_6=rep("MATHEMATICS", 6),
MATHEMATICS_GRADE_7=rep("MATHEMATICS", 6),
MATHEMATICS_GRADE_8=rep("MATHEMATICS", 6))
SGPstateData[["HI"]][["SGP_Configuration"]][["max.forward.projection.sequence"]] <- list(
READING_GRADE_3=3,
READING_GRADE_4=3,
READING_GRADE_5=3,
READING_GRADE_6=3,
READING_GRADE_7=3,
READING_GRADE_8=3,
MATHEMATICS_GRADE_3=3,
MATHEMATICS_GRADE_4=3,
MATHEMATICS_GRADE_5=3,
MATHEMATICS_GRADE_6=3,
MATHEMATICS_GRADE_7=3,
MATHEMATICS_GRADE_8=3)
### Run analysis
Hawaii_SGP <- abcSGP(
Hawaii_SGP,
years = "2021", # need to add years now (after adding 2019 baseline projections). Why?
steps=c("prepareSGP", "analyzeSGP", "combineSGP"),
sgp.config=HI_CONFIG,
sgp.percentiles=FALSE,
sgp.projections=FALSE,
sgp.projections.lagged=FALSE,
sgp.percentiles.baseline=FALSE,
sgp.projections.baseline=TRUE,
sgp.projections.lagged.baseline=FALSE,
sgp.target.scale.scores=TRUE,
outputSGP.directory=output.directory,
parallel.config=parallel.config
)
### Save results
save(Hawaii_SGP, file="Data/Hawaii_SGP.Rdata")