Skip to content

Commit d058134

Browse files
committed
Minor fix to outputVar json creation.
1 parent 1eed427 commit d058134

File tree

4 files changed

+20
-22
lines changed

4 files changed

+20
-22
lines changed
Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,14 @@
11
[
22
{
33
"name": "EM_EVENTPROBABILITY",
4-
"length": 8,
5-
"type": "decimal",
6-
"level": "interval"
7-
},
8-
{
9-
"name": "EM_CLASSIFICATION",
104
"length": 1,
115
"type": "string",
126
"level": "nominal"
7+
},
8+
{
9+
"name": "EM_CLASSIFICATION",
10+
"length": 8,
11+
"type": "decimal",
12+
"level": "interval"
1313
}
1414
]
Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,14 @@
11
[
22
{
33
"name": "EM_EVENTPROBABILITY",
4-
"length": 8,
5-
"type": "decimal",
6-
"level": "interval"
7-
},
8-
{
9-
"name": "EM_CLASSIFICATION",
104
"length": 1,
115
"type": "string",
126
"level": "nominal"
7+
},
8+
{
9+
"name": "EM_CLASSIFICATION",
10+
"length": 8,
11+
"type": "decimal",
12+
"level": "interval"
1313
}
1414
]
Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,14 @@
11
[
22
{
33
"name": "EM_EVENTPROBABILITY",
4-
"length": 8,
5-
"type": "decimal",
6-
"level": "interval"
7-
},
8-
{
9-
"name": "EM_CLASSIFICATION",
104
"length": 1,
115
"type": "string",
126
"level": "nominal"
7+
},
8+
{
9+
"name": "EM_CLASSIFICATION",
10+
"length": 8,
11+
"type": "decimal",
12+
"level": "interval"
1313
}
1414
]

examples/pzmmModelImportExample.ipynb

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -635,7 +635,7 @@
635635
},
636636
{
637637
"cell_type": "code",
638-
"execution_count": 13,
638+
"execution_count": 20,
639639
"metadata": {
640640
"Collapsed": "false"
641641
},
@@ -667,9 +667,7 @@
667667
" J.writeVarJSON(data[predict], isInput=True, jPath=zipFolder)\n",
668668
" \n",
669669
" # Set output variables and assign an event threshold, then write output variable mapping\n",
670-
" outputVar = pd.DataFrame(columns=['EM_EVENTPROBABILITY', 'EM_CLASSIFICATION'])\n",
671-
" outputVar['EM_CLASSIFICATION'].loc[1] = 'A'#yTrain.astype('category').cat.categories.astype('str')\n",
672-
" outputVar['EM_EVENTPROBABILITY'].loc[1] = 0.5 # Event threshold\n",
670+
" outputVar = pd.DataFrame(columns=['EM_EVENTPROBABILITY', 'EM_CLASSIFICATION'], data=[['A', 0.5]]) # data argument includes example expected types for columns\n",
673671
" J.writeVarJSON(outputVar, isInput=False, jPath=zipFolder)\n",
674672
" \n",
675673
" # Write model properties to a json file\n",

0 commit comments

Comments
 (0)