mirror of
https://github.com/reiyua/HospitalWaitTimeCalc.git
synced 2026-11-17 06:12:05 +11:00
Modify notebook to prevent negative waiting times
This commit is contained in:
parent
d67d5a6612
commit
5c12bb7380
1 changed files with 18 additions and 4 deletions
|
|
@ -2335,7 +2335,8 @@
|
|||
"metadata": {},
|
||||
"outputs": [],
|
||||
"source": [
|
||||
"y_pred = model.predict(X_test)"
|
||||
"y_pred = model.predict(X_test)\n",
|
||||
"y_pred = np.clip(y_pred, a_min=0, a_max=None) # Forces negative wait times to be 0"
|
||||
]
|
||||
},
|
||||
{
|
||||
|
|
@ -2926,11 +2927,24 @@
|
|||
},
|
||||
{
|
||||
"cell_type": "code",
|
||||
"execution_count": 41,
|
||||
"execution_count": 1,
|
||||
"metadata": {},
|
||||
"outputs": [],
|
||||
"outputs": [
|
||||
{
|
||||
"ename": "NameError",
|
||||
"evalue": "name 'model' is not defined",
|
||||
"output_type": "error",
|
||||
"traceback": [
|
||||
"\u001b[31m---------------------------------------------------------------------------\u001b[39m",
|
||||
"\u001b[31mNameError\u001b[39m Traceback (most recent call last)",
|
||||
"\u001b[36mCell\u001b[39m\u001b[36m \u001b[39m\u001b[32mIn[1]\u001b[39m\u001b[32m, line 1\u001b[39m\n\u001b[32m----> \u001b[39m\u001b[32m1\u001b[39m y_pred = \u001b[43mmodel\u001b[49m.predict(X_test)\n",
|
||||
"\u001b[31mNameError\u001b[39m: name 'model' is not defined"
|
||||
]
|
||||
}
|
||||
],
|
||||
"source": [
|
||||
"y_pred = model.predict(X_test)"
|
||||
"y_pred = model.predict(X_test)\n",
|
||||
"y_pred = np.clip(y_pred, a_min=0, a_max=None) # Forces negative wait times to be 0"
|
||||
]
|
||||
},
|
||||
{
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue