-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathdatapackage.json
287 lines (287 loc) · 8.07 KB
/
datapackage.json
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
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
{
"name": "drug-arrests",
"datapackage_version": "1.0-beta.18",
"title": "Drug Arrests",
"description": "Drug Arrests reports the number and rate (per 10,000) of arrests due to drug law offenses, per age range.",
"version": "1.0",
"licenses": [{
"url": "http://opendatacommons.org/licenses/pddl/",
"name": "Open Data Commons Public Domain",
"version": "1.0",
"id": "odc-pddl"
}],
"sources": [{
"name": "ctdespp",
"web": ""
}],
"author":[{
"name": "Connecticut Data Collaborative",
"email": "[email protected]",
"web": "http://ctdata.org"
}],
"contributor": [],
"resources": [{
"path": "data/drug-arrests_2016.csv",
"format": "csv",
"schema": {
"fields": [{
"name": "Town",
"type": "string",
"dimension": false
}, {
"name": "FIPS",
"type": "string",
"dimension": false
}, {
"name": "Year",
"type": "string",
"dimension": false
}, {
"name": "Age Range",
"type": "string",
"dimension": true,
"constraints": {
"enum": [
"Total",
"10 years and over",
"10 to 17 years",
"18 to 24 years",
"18 years and over"
]
}
}, {
"name": "Measure Type",
"type": "string",
"dimension": true,
"constraints": {
"enum": [
"Number",
"Rate (per 10,000)"
]
}
}, {
"name": "Variable",
"type": "string",
"dimension": true,
"constraints": {
"enum": [
"Drug Arrests",
"Margins of Error"
]
}
}, {
"name": "Value",
"type": "number",
"dimension": false
}]
}
}
],
"last_modified": "01/11/2019",
"ckan_extras": {
"full_description": {
"ckan_name": "Full Description",
"value": "The Connecticut Department of Emergency Services and Public Protection (prior to 2011 called the Department of Public Safety) collects and reports crime data in the Uniform Crime Report (UCR) program. This data reports the number of arrests, and is collected and reported to the state by each agency monthly. The DESPP reports this collected data annually. CTData has aggregated agency data in two locations to create a uniform level of reporting. For the town of Putnam, the Municipal Police Department and Connecticut State Police agency data has been aggregated. For Groton, the data covering the Town of Groton, the City of Groton, and Groton Long Point have been aggregated. Drug offenses include possession, sale, use, growing, and manufacturing of narcotic drugs. The denominators for the rates are derived from 5-Year ACS population figures. As such, the rate of arrests is given with a Margin of Error calculated from the Margin of Error present in the population data.",
"type": "string"
},
"suppression": {
"ckan_name": "Suppression",
"value": "",
"type": "string"
},
"technical_notes": {
"ckan_name": "Technical Notes",
"value": "To calculate the rate for a specified indicator age range, the number of drug arrests within the specified age range is divided by the population within the specified age range and multiplied by 10,000.",
"type": "string"
},
"socrata": {
"ckan_name": "Socrata",
"value": "True",
"type": "string"
},
"socrata_url": {
"ckan_name": "Socrata Dataset URL",
"value": "https://data.ct.gov/Public-Safety/Uniform-Crime-Reporting-System-Arrests-2016/64f7-5788",
"type": "string"
},
"socrata_dataset_name": {
"ckan_name": "Socrata Dataset Name",
"value": "Uniform Crime Reporting System Arrests",
"type": "string"
},
"domain": {
"ckan_name": "Domain",
"value": "Health",
"type": "string"
},
"subdomain": {
"ckan_name": "Subdomain",
"value": "Substance Abuse",
"type": "string"
},
"numerator": {
"ckan_name": "Numerator",
"value": "Number of drug offenses per age group.",
"type": "string"
},
"denominator": {
"ckan_name": "Denominator",
"value": "Population for age group, reported by the US Census.",
"type": "string"
},
"geography": {
"ckan_name": "Geography",
"value": "Town",
"type": "string",
"constraints": {"enum": ["Town", "County", "Town/County", "District", "Other"]}
},
"frequency": {
"ckan_name": "Frequency",
"value": "Annual",
"type": "string"
},
"years_in_catalog": {
"ckan_name": "Years in Catalog",
"value": ["2010", "2011", "2012", "2013", "2014", "2015", "2016"],
"type": "array"
},
"latest_year": {
"ckan_name": "Latest Year Available",
"value": "2016",
"type": "string"
},
"disabled_views": {
"ckan_name": "Disabled Views",
"value": [],
"type": "array",
"constraints": {"enum": ["map", "table", "bar", "line"]}
},
"units": {
"ckan_name": "Units",
"value": {
"Number": "",
"Percent": "%"
}
},
"expected_number_of_geographies": {
"ckan_name": "Expected Number of Unique Geographies",
"value": 170,
"type": "string"
},
"default": {
"ckan_name": "Default",
"value": {
"Town": "Connecticut",
"Year": "2016",
"Measure Type": ["Number", "Rate (per 10,000)"],
"Variable": ["Drug Arrests"],
"Age Range": "Total"
},
"type": "object"
}
},
"spot_checks": [
{
"type": "$lookup",
"filter": {
"Town": "Middletown",
"Year": "2010",
"Age Range": "Total",
"Variable": "Drug Arrests",
"Measure Type": "Number"
},
"expected": {
"type": "$match",
"number type": "int",
"value": 376
}
},
{
"type": "$lookup",
"filter": {
"Town": "Groton",
"Year": "2011",
"Age Range": "10 years and over",
"Variable": "Margins of Error",
"Measure Type": "Rate (per 10,000)"
},
"expected": {
"type": "$match",
"number type": "float",
"value": 1.07
}
},
{
"type": "$lookup",
"filter": {
"Town": "Putnam",
"Year": "2012",
"Age Range": "10 to 17 years",
"Variable": "Drug Arrests",
"Measure Type": "Number"
},
"expected": {
"type": "$match",
"number type": "int",
"value": 4
}
},
{
"type": "$lookup",
"filter": {
"Town": "Tolland",
"Year": "2013",
"Variable": "Drug Arrests",
"Age Range": "18 to 24 years",
"Measure Type": "Rate (per 10,000)"
},
"expected": {
"type": "$match",
"number type": "float",
"value": 30.15
}
},
{
"type": "$lookup",
"filter": {
"Town": "Hartford",
"Year": "2014",
"Age Range": "18 years and over",
"Variable": "Drug Arrests",
"Measure Type": "Number"
},
"expected": {
"type": "$match",
"number type": "int",
"value": 1017
}
},
{
"type": "$lookup",
"filter": {
"Town": "Connecticut",
"Year": "2015",
"Age Range": "Total",
"Variable": "Drug Arrests",
"Measure Type": "Rate (per 10,000)"
},
"expected": {
"type": "$match",
"number type": "float",
"value": 23.12
}
}
],
"dimension_groups": [
{
"Measure Type": ["Number"],
"Age Range": ["Total", "10 years and over", "10 to 17 years", "18 to 24 years", "18 years and over"],
"Variable": ["Drug Arrests"]
},
{
"Measure Type": ["Rate per (10,000)"],
"Age Range": ["Total", "10 years and over", "10 to 17 years", "18 to 24 years", "18 years and over"],
"Variable": ["Drug Arrests", "Margins of Error"]
}
]
}