Skip to content

Commit

Permalink
[DOC] fix failing cells in detection notebook after skchange update (
Browse files Browse the repository at this point in the history
…#7483)

This PR fixes a few failing cells in detection notebook after the recent
`skchange` update.
  • Loading branch information
fkiraly authored Dec 5, 2024
1 parent 2f42990 commit cc1f7bd
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions examples/07_detection_anomaly_changepoints.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -623,7 +623,7 @@
},
{
"cell_type": "code",
"execution_count": 12,
"execution_count": null,
"id": "9dbdfa3d-9fa3-4f5f-b9b5-a4a8d84fe12e",
"metadata": {},
"outputs": [
Expand All @@ -637,8 +637,8 @@
}
],
"source": [
"print(\"left: \", anomaly_intervals.iat[0].left)\n",
"print(\"right: \", anomaly_intervals.iat[0].right)"
"print(\"left: \", anomaly_intervals.ilocs[0].left)\n",
"print(\"right: \", anomaly_intervals.ilocs[0].right)"
]
},
{
Expand All @@ -653,7 +653,7 @@
},
{
"cell_type": "code",
"execution_count": 13,
"execution_count": null,
"id": "1409870e-bdb2-4fd1-870f-7feb9f9efd9c",
"metadata": {},
"outputs": [
Expand Down Expand Up @@ -683,7 +683,7 @@
"ax.plot(df[\"data\"], label=\"Not Anomalous\")\n",
"ax.plot(df.loc[df[\"label\"] == 1.0, \"data\"], label=\"Anomalous\")\n",
"\n",
"for interval in anomaly_intervals:\n",
"for interval in anomaly_intervals.ilocs:\n",
" left = interval.left\n",
" right = interval.right\n",
" ax.axvspan(left, right, color=\"tab:green\", alpha=0.3, label=\"Predicted Anomalies\")\n",
Expand Down

0 comments on commit cc1f7bd

Please sign in to comment.