-
Notifications
You must be signed in to change notification settings - Fork 0
/
LDT_Addendum.py
168 lines (160 loc) · 6.22 KB
/
LDT_Addendum.py
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
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
## Version of the Leakdown Tester
ldtVersion = "1.3.0"
## JSON content 'header' wrapper section for in-situ payload compilation:
payloadHeader = '''
{
"@context": {
"@vocab": "http://schema.org/",
"slowmo": "http://example.com/slowmo#",
"csvw": "http://www.w3.org/ns/csvw#",
"dc": "http://purl.org/dc/terms/",
"psdo": "http://purl.obolibrary.org/obo/",
"slowmo:Measure": "http://example.com/slowmo#Measure",
"slowmo:IsAboutPerformer": "http://example.com/slowmo#IsAboutPerformer",
"slowmo:ColumnUse": "http://example.com/slowmo#ColumnUse",
"slowmo:IsAboutTemplate": "http://example.com/slowmo#IsAboutTemplate",
"slowmo:spek": "http://example.com/slowmo#spek",
"slowmo:IsAboutCausalPathway": "http://example.com/slowmo#IsAboutCausalPathway",
"slowmo:IsAboutOrganization": "http://example.com/slowmo#IsAboutOrganization",
"slowmo:IsAboutMeasure": "http://example.com/slowmo#IsAboutMeasure",
"slowmo:InputTable": "http://example.com/slowmo#InputTable",
"slowmo:WithComparator": "http://example.com/slowmo#WithComparator",
"has_part": "http://purl.obolibrary.org/obo/bfo#BFO_0000051",
"has_disposition": "http://purl.obolibrary.org/obo/RO_0000091"
},
"Performance_data":[
["staff_number","measure","month","passed_count","flagged_count","denominator","peer_average_comparator","peer_90th_percentile_benchmark","peer_75th_percentile_benchmark","MPOG_goal"],
'''
## Direct ref performance data for individual tweaks
postwoman = '''
[6,"NMB03","2023-01-01",90,10,100,90,92,96,90],
[6,"NMB03","2023-02-01",90,10,100,90,92,96,90],
[6,"NMB03","2023-03-01",90,10,100,90,92,96,90],
[6,"NMB03","2023-04-01",90,10,100,90,92,96,90],
[6,"NMB03","2023-05-01",90,10,100,90,92,96,90],
[6,"NMB03","2023-06-01",90,10,100,90,92,96,90],
[6,"NMB03","2023-07-01",90,10,100,90,92,96,90],
[6,"NMB03","2023-08-01",90,10,100,90,92,96,90],
[6,"NMB03","2023-09-01",90,10,100,90,92,96,90],
[6,"NMB03","2023-10-01",90,10,100,90,92,96,90],
[6,"NMB03","2023-11-01",100,0,100,90,92,96,90],
[6,"NMB03","2023-12-01",1,1,2,90,92,96,90]
'''
## JSON content 'footer' wrapper section for in-situ payload compilation:
payloadFooter = '''
],
"History":{
},
"Preferences":{
"Utilities": {
"Message_Format":
{
"1": "0.0",
"2": "0.1",
"16": "7.5",
"24": "9.4",
"18": "11.3",
"11": "13.2",
"22": "15.1" ,
"14": "22.6" ,
"21": "62.3" ,
"5":"0.2",
"15":"4.0",
"4":"0.9"
},
"Display_Format":
{
"short_sentence_with_no_chart": "0.0",
"bar": "37.0",
"line": "0.0"
}
}
}
}
'''
## Dictionary of vignette-determined persona, measure, and causal pathway pairings:
vignAccPairs = {
1: [
{"acceptable_by": "social loss", "measure": "PONV05"},
{"acceptable_by": "social better", "measure": "SUS04"},
{"acceptable_by": "goal approach", "measure": "GLU03"}
],
2: [
{"acceptable_by": "social loss", "measure": "PONV05"},
{"acceptable_by": "social approach", "measure": "TOC02"}
],
3: [
{"acceptable_by": "social gain", "measure": "PUL01"},
{"acceptable_by": "goal approach", "measure": "GLU03"}
],
4: [
{"acceptable_by": "social worse", "measure": "GLU01"},
{"acceptable_by": "social approach", "measure": "TOC02"},
{"acceptable_by": "improving", "measure": "BP03"}
],
5: [
{"acceptable_by": "social worse", "measure": "GLU01"},
{"acceptable_by": "goal gain", "measure": "TOC01"}
],
6: [
{"acceptable_by": "social gain", "measure": "PUL01"},
{"acceptable_by": "worsening", "measure": "SUS02"},
{"acceptable_by": "goal loss", "measure": "NMB03"}
],
7: [
{"acceptable_by": "social better", "measure": "SUS04"},
{"acceptable_by": "improving", "measure": "BP03"},
{"acceptable_by": "worsening", "measure": "SUS02"},
{"acceptable_by": "goal loss", "measure": "NMB03"},
{"acceptable_by": "goal gain", "measure": "TOC01"}
]
}
pilotPairs = {
1: [
{"acceptable_by": "social worse", "measure": "PONV05"}, # to 75th, 90th
{"acceptable_by": "social better", "measure": "SUS04"}, # to 50th, 75th, 90th
{"acceptable_by": "social worse", "measure": "GLU03"} # to 50th, 75th, 90th
],
2: [
{"acceptable_by": "social worse", "measure": "PONV05"}, # to 50th, 75th, 90th
{"acceptable_by": "social worse", "measure": "TOC02"} # to 75th, 90th
],
3: [
{"acceptable_by": "social better", "measure": "PUL01"}, # to 50th, 75th
{"acceptable_by": "social worse", "measure": "GLU03"} # to 75th, 90th
],
4: [
{"acceptable_by": "social worse", "measure": "GLU01"}, # to 90th
{"acceptable_by": "social worse", "measure": "TOC02"}, # to 90th
{"acceptable_by": "social better", "measure": "BP03"} # to 50th, 75th
],
5: [
{"acceptable_by": "social worse", "measure": "GLU01"}, # to 50th, 75th, 90th
{"acceptable_by": "social better", "measure": "TOC01"} # to 50th, 75th
],
6: [
{"acceptable_by": "social better", "measure": "PUL01"}, # to 50th, 75th, 90th
{"acceptable_by": "social better", "measure": "SUS04"}, # to 50th, 75th
{"acceptable_by": "social worse", "measure": "NMB03"} # to 50th, 7th, 90th
],
7: [
{"acceptable_by": "social better", "measure": "SUS04"}, # to 50th
{"acceptable_by": "social better", "measure": "BP03"}, # to 50th, 75th
{"acceptable_by": "social worse", "measure": "SUS02"}, # to 50th, 75th, 90th
{"acceptable_by": "social worse", "measure": "NMB03"}, # to 50th, 75th, 90th
{"acceptable_by": "social worse", "measure": "TOC01"} # to 90th
]
}
## Repo Testing dictionaries:
hitlistIM = ["alice", "bob", "chikondi", "deepa", "eugene", "fahad", "gaile"]
hitlistCP = ["goal_approach",
"goal_gain",
"goal_loss",
"improving",
"social_approach",
"social_better",
"social_gain",
"social_loss",
"social_worse",
"worsening"
]