{
 "cells": [
  {
   "cell_type": "markdown",
   "id": "af9a385a",
   "metadata": {},
   "source": [
    "# 2020 / 2021\n",
    "\n",
    "Progress points for the EFL League One 2020 / 2021 season."
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 1,
   "id": "1bd3523a",
   "metadata": {
    "execution": {
     "iopub.execute_input": "2025-11-03T19:56:10.446028Z",
     "iopub.status.busy": "2025-11-03T19:56:10.445907Z",
     "iopub.status.idle": "2025-11-03T19:56:10.742626Z",
     "shell.execute_reply": "2025-11-03T19:56:10.742163Z"
    }
   },
   "outputs": [],
   "source": [
    "%config InlineBackend.figure_formats = ['svg']\n",
    "from proggyleg import proggyleg\n",
    "year = 2020\n",
    "league = \"E2\""
   ]
  },
  {
   "cell_type": "markdown",
   "id": "7961f9b7",
   "metadata": {},
   "source": [
    "## Cumulative Points\n",
    "\n",
    "The sum of points up to a given game played."
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 2,
   "id": "9158206a",
   "metadata": {
    "execution": {
     "iopub.execute_input": "2025-11-03T19:56:10.744168Z",
     "iopub.status.busy": "2025-11-03T19:56:10.744007Z",
     "iopub.status.idle": "2025-11-03T19:56:12.519865Z",
     "shell.execute_reply": "2025-11-03T19:56:12.519406Z"
    }
   },
   "outputs": [
    {
     "data": {
      "image/svg+xml": [
       ""
      ],
      "text/plain": [
       ""
      ]
     },
     "metadata": {
      "needs_background": "light"
     },
     "output_type": "display_data"
    }
   ],
   "source": [
    "proggyleg.autoplot(year, league, which=\"cumulative\");"
   ]
  },
  {
   "cell_type": "markdown",
   "id": "e834ca44",
   "metadata": {},
   "source": [
    "## Extrapolated Points\n",
    "\n",
    "Final points assuming each team continues to score points at the same rate as they have so far."
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 3,
   "id": "3064525a",
   "metadata": {
    "execution": {
     "iopub.execute_input": "2025-11-03T19:56:12.522437Z",
     "iopub.status.busy": "2025-11-03T19:56:12.522293Z",
     "iopub.status.idle": "2025-11-03T19:56:12.792589Z",
     "shell.execute_reply": "2025-11-03T19:56:12.792114Z"
    }
   },
   "outputs": [
    {
     "data": {
      "image/svg+xml": [
       ""
      ],
      "text/plain": [
       ""
      ]
     },
     "metadata": {
      "needs_background": "light"
     },
     "output_type": "display_data"
    }
   ],
   "source": [
    "proggyleg.autoplot(year, league, which=\"extrapolated\");"
   ]
  },
  {
   "cell_type": "markdown",
   "id": "2d26b750",
   "metadata": {},
   "source": [
    "## Position"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 4,
   "id": "eaab2f0e",
   "metadata": {
    "execution": {
     "iopub.execute_input": "2025-11-03T19:56:12.794712Z",
     "iopub.status.busy": "2025-11-03T19:56:12.794590Z",
     "iopub.status.idle": "2025-11-03T19:56:13.064542Z",
     "shell.execute_reply": "2025-11-03T19:56:13.064096Z"
    }
   },
   "outputs": [
    {
     "data": {
      "image/svg+xml": [
       ""
      ],
      "text/plain": [
       ""
      ]
     },
     "metadata": {
      "needs_background": "light"
     },
     "output_type": "display_data"
    }
   ],
   "source": [
    "proggyleg.autoplot(year, league, which=\"position\");"
   ]
  },
  {
   "cell_type": "markdown",
   "id": "3895ba3c",
   "metadata": {},
   "source": [
    "## Rolling Form\n",
    "\n",
    "Exponential weighted moving average of points won per game."
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 5,
   "id": "d85c6a20",
   "metadata": {
    "execution": {
     "iopub.execute_input": "2025-11-03T19:56:13.066720Z",
     "iopub.status.busy": "2025-11-03T19:56:13.066583Z",
     "iopub.status.idle": "2025-11-03T19:56:13.350367Z",
     "shell.execute_reply": "2025-11-03T19:56:13.349963Z"
    }
   },
   "outputs": [
    {
     "data": {
      "image/svg+xml": [
       ""
      ],
      "text/plain": [
       ""
      ]
     },
     "metadata": {
      "needs_background": "light"
     },
     "output_type": "display_data"
    }
   ],
   "source": [
    "proggyleg.autoplot(year, league, which=\"form\");"
   ]
  }
 ],
 "metadata": {
  "kernelspec": {
   "display_name": "Python 3",
   "language": "python",
   "name": "python3"
  },
  "language_info": {
   "codemirror_mode": {
    "name": "ipython",
    "version": 3
   },
   "file_extension": ".py",
   "mimetype": "text/x-python",
   "name": "python",
   "nbconvert_exporter": "python",
   "pygments_lexer": "ipython3",
   "version": "3"
  },
  "mystnb": {
   "execution_mode": "off"
  }
 },
 "nbformat": 4,
 "nbformat_minor": 5
}