sportowe_wizualizacja/PassMap.ipynb

2326 lines
158 KiB
Plaintext
Raw Normal View History

2019-06-03 13:31:10 +02:00
{
"cells": [
{
"cell_type": "code",
"execution_count": 18,
"metadata": {},
"outputs": [
{
"name": "stdout",
"output_type": "stream",
"text": [
"done\n"
]
}
],
"source": [
"import json\n",
"import os\n",
"from pandas.io.json import json_normalize\n",
"import numpy as np\n",
"import seaborn as sns\n",
"import pandas as pd\n",
"import matplotlib.pyplot as plt\n",
"from matplotlib.patches import Arc, Rectangle, ConnectionPatch\n",
"from matplotlib.offsetbox import OffsetImage\n",
"#import squarify\n",
"from functools import reduce\n",
"path = \"\"\"C:\\\\Users\\\\Koushik\\\\Downloads\\\\open-data-master\\\\open-data-master\\\\data\\\\my_events\\\\\"\"\"\n",
"Xg_req = pd.DataFrame(data=None)\n",
"for filename in (os.listdir(path)):\n",
" #print(filename)\n",
" \n",
" with open(\"%s\" % path + filename,encoding=\"utf8\") as data_file: \n",
" data = json.load(data_file)\n",
" df = pd.DataFrame(data=None)\n",
" \n",
" df = json_normalize(data, sep = \"_\")\n",
" \n",
" #df = df[(df['type_name'] == \"Shot\")]\n",
" #df = df.loc[:,['location','shot_body_part_id','shot_end_location','shot_one_on_one','shot_technique_id','shot_type_id','under_pressure','shot_outcome_id']]\n",
" #print(df.shape)\n",
" Xg_req = Xg_req.append(df,ignore_index=True,sort=False)\n",
" #df.drop(df.index, inplace=True)\n",
" \n",
"print(\"done\")\n",
"df = Xg_req"
]
},
{
"cell_type": "code",
"execution_count": 32,
"metadata": {
"scrolled": true
},
"outputs": [
{
"data": {
"text/html": [
"<div>\n",
"<style scoped>\n",
" .dataframe tbody tr th:only-of-type {\n",
" vertical-align: middle;\n",
" }\n",
"\n",
" .dataframe tbody tr th {\n",
" vertical-align: top;\n",
" }\n",
"\n",
" .dataframe thead th {\n",
" text-align: right;\n",
" }\n",
"</style>\n",
"<table border=\"1\" class=\"dataframe\">\n",
" <thead>\n",
" <tr style=\"text-align: right;\">\n",
" <th></th>\n",
" <th>bad_behaviour_card_id</th>\n",
" <th>bad_behaviour_card_name</th>\n",
" <th>ball_receipt_outcome_id</th>\n",
" <th>ball_receipt_outcome_name</th>\n",
" <th>ball_recovery_offensive</th>\n",
" <th>ball_recovery_recovery_failure</th>\n",
" <th>block_deflection</th>\n",
" <th>dribble_nutmeg</th>\n",
" <th>dribble_outcome_id</th>\n",
" <th>dribble_outcome_name</th>\n",
" <th>...</th>\n",
" <th>pass_miscommunication</th>\n",
" <th>shot_aerial_won</th>\n",
" <th>shot_open_goal</th>\n",
" <th>50_50_outcome_id</th>\n",
" <th>50_50_outcome_name</th>\n",
" <th>block_offensive</th>\n",
" <th>miscontrol_aerial_won</th>\n",
" <th>foul_committed_penalty</th>\n",
" <th>shot_deflected</th>\n",
" <th>shot_redirect</th>\n",
" </tr>\n",
" </thead>\n",
" <tbody>\n",
" <tr>\n",
" <th>204</th>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>...</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" </tr>\n",
" <tr>\n",
" <th>749</th>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>...</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" </tr>\n",
" <tr>\n",
" <th>1651</th>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>...</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" </tr>\n",
" <tr>\n",
" <th>2741</th>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>...</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" </tr>\n",
" <tr>\n",
" <th>3890</th>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>...</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" </tr>\n",
" <tr>\n",
" <th>4594</th>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>...</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>True</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" </tr>\n",
" <tr>\n",
" <th>4647</th>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>...</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" </tr>\n",
" <tr>\n",
" <th>4784</th>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>...</td>\n",
" <td>NaN</td>\n",
" <td>True</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" </tr>\n",
" <tr>\n",
" <th>4918</th>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>...</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" </tr>\n",
" <tr>\n",
" <th>6271</th>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>...</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" </tr>\n",
" <tr>\n",
" <th>7406</th>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>...</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" </tr>\n",
" <tr>\n",
" <th>7924</th>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>...</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" </tr>\n",
" <tr>\n",
" <th>9525</th>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>...</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" </tr>\n",
" <tr>\n",
" <th>10606</th>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>...</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" </tr>\n",
" <tr>\n",
" <th>10877</th>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>...</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>True</td>\n",
" <td>NaN</td>\n",
" </tr>\n",
" <tr>\n",
" <th>12291</th>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>...</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" </tr>\n",
" <tr>\n",
" <th>13231</th>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>...</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" </tr>\n",
" <tr>\n",
" <th>13839</th>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>...</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" </tr>\n",
" <tr>\n",
" <th>13975</th>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>...</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" </tr>\n",
" <tr>\n",
" <th>14105</th>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>...</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" </tr>\n",
" <tr>\n",
" <th>14173</th>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>...</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" </tr>\n",
" <tr>\n",
" <th>14561</th>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>...</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" </tr>\n",
" <tr>\n",
" <th>15815</th>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>...</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" </tr>\n",
" <tr>\n",
" <th>15894</th>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>...</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>True</td>\n",
" <td>NaN</td>\n",
" </tr>\n",
" <tr>\n",
" <th>15928</th>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>...</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" </tr>\n",
" <tr>\n",
" <th>19882</th>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>...</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" </tr>\n",
" <tr>\n",
" <th>20227</th>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>...</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" </tr>\n",
" <tr>\n",
" <th>20823</th>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>...</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" </tr>\n",
" <tr>\n",
" <th>20917</th>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>...</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" </tr>\n",
" <tr>\n",
" <th>21975</th>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>...</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" </tr>\n",
" <tr>\n",
" <th>...</th>\n",
" <td>...</td>\n",
" <td>...</td>\n",
" <td>...</td>\n",
" <td>...</td>\n",
" <td>...</td>\n",
" <td>...</td>\n",
" <td>...</td>\n",
" <td>...</td>\n",
" <td>...</td>\n",
" <td>...</td>\n",
" <td>...</td>\n",
" <td>...</td>\n",
" <td>...</td>\n",
" <td>...</td>\n",
" <td>...</td>\n",
" <td>...</td>\n",
" <td>...</td>\n",
" <td>...</td>\n",
" <td>...</td>\n",
" <td>...</td>\n",
" <td>...</td>\n",
" </tr>\n",
" <tr>\n",
" <th>152707</th>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>...</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>True</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" </tr>\n",
" <tr>\n",
" <th>155048</th>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>...</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" </tr>\n",
" <tr>\n",
" <th>158183</th>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>...</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" </tr>\n",
" <tr>\n",
" <th>161937</th>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>...</td>\n",
" <td>NaN</td>\n",
" <td>True</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" </tr>\n",
" <tr>\n",
" <th>162329</th>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>...</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" </tr>\n",
" <tr>\n",
" <th>163634</th>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>...</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" </tr>\n",
" <tr>\n",
" <th>163781</th>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>...</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" </tr>\n",
" <tr>\n",
" <th>164961</th>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>...</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" </tr>\n",
" <tr>\n",
" <th>165854</th>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>...</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" </tr>\n",
" <tr>\n",
" <th>166107</th>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>...</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>True</td>\n",
" </tr>\n",
" <tr>\n",
" <th>166301</th>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>...</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" </tr>\n",
" <tr>\n",
" <th>166464</th>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>...</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" </tr>\n",
" <tr>\n",
" <th>166557</th>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>...</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" </tr>\n",
" <tr>\n",
" <th>167304</th>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>...</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" </tr>\n",
" <tr>\n",
" <th>168706</th>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>...</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" </tr>\n",
" <tr>\n",
" <th>171222</th>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>...</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" </tr>\n",
" <tr>\n",
" <th>171224</th>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>...</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" </tr>\n",
" <tr>\n",
" <th>171226</th>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>...</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" </tr>\n",
" <tr>\n",
" <th>171228</th>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>...</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" </tr>\n",
" <tr>\n",
" <th>171232</th>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>...</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" </tr>\n",
" <tr>\n",
" <th>171234</th>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>...</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" </tr>\n",
" <tr>\n",
" <th>171236</th>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>...</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" </tr>\n",
" <tr>\n",
" <th>172725</th>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>...</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>True</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" </tr>\n",
" <tr>\n",
" <th>173646</th>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>...</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>True</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" </tr>\n",
" <tr>\n",
" <th>175473</th>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>...</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" </tr>\n",
" <tr>\n",
" <th>175627</th>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>...</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" </tr>\n",
" <tr>\n",
" <th>176100</th>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>...</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" </tr>\n",
" <tr>\n",
" <th>176213</th>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>...</td>\n",
" <td>NaN</td>\n",
" <td>True</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" </tr>\n",
" <tr>\n",
" <th>176750</th>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>...</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" </tr>\n",
" <tr>\n",
" <th>178726</th>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>...</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>NaN</td>\n",
" <td>True</td>\n",
" <td>NaN</td>\n",
" </tr>\n",
" </tbody>\n",
"</table>\n",
"<p>200 rows × 118 columns</p>\n",
"</div>"
],
"text/plain": [
" bad_behaviour_card_id bad_behaviour_card_name \\\n",
"204 NaN NaN \n",
"749 NaN NaN \n",
"1651 NaN NaN \n",
"2741 NaN NaN \n",
"3890 NaN NaN \n",
"4594 NaN NaN \n",
"4647 NaN NaN \n",
"4784 NaN NaN \n",
"4918 NaN NaN \n",
"6271 NaN NaN \n",
"7406 NaN NaN \n",
"7924 NaN NaN \n",
"9525 NaN NaN \n",
"10606 NaN NaN \n",
"10877 NaN NaN \n",
"12291 NaN NaN \n",
"13231 NaN NaN \n",
"13839 NaN NaN \n",
"13975 NaN NaN \n",
"14105 NaN NaN \n",
"14173 NaN NaN \n",
"14561 NaN NaN \n",
"15815 NaN NaN \n",
"15894 NaN NaN \n",
"15928 NaN NaN \n",
"19882 NaN NaN \n",
"20227 NaN NaN \n",
"20823 NaN NaN \n",
"20917 NaN NaN \n",
"21975 NaN NaN \n",
"... ... ... \n",
"152707 NaN NaN \n",
"155048 NaN NaN \n",
"158183 NaN NaN \n",
"161937 NaN NaN \n",
"162329 NaN NaN \n",
"163634 NaN NaN \n",
"163781 NaN NaN \n",
"164961 NaN NaN \n",
"165854 NaN NaN \n",
"166107 NaN NaN \n",
"166301 NaN NaN \n",
"166464 NaN NaN \n",
"166557 NaN NaN \n",
"167304 NaN NaN \n",
"168706 NaN NaN \n",
"171222 NaN NaN \n",
"171224 NaN NaN \n",
"171226 NaN NaN \n",
"171228 NaN NaN \n",
"171232 NaN NaN \n",
"171234 NaN NaN \n",
"171236 NaN NaN \n",
"172725 NaN NaN \n",
"173646 NaN NaN \n",
"175473 NaN NaN \n",
"175627 NaN NaN \n",
"176100 NaN NaN \n",
"176213 NaN NaN \n",
"176750 NaN NaN \n",
"178726 NaN NaN \n",
"\n",
" ball_receipt_outcome_id ball_receipt_outcome_name \\\n",
"204 NaN NaN \n",
"749 NaN NaN \n",
"1651 NaN NaN \n",
"2741 NaN NaN \n",
"3890 NaN NaN \n",
"4594 NaN NaN \n",
"4647 NaN NaN \n",
"4784 NaN NaN \n",
"4918 NaN NaN \n",
"6271 NaN NaN \n",
"7406 NaN NaN \n",
"7924 NaN NaN \n",
"9525 NaN NaN \n",
"10606 NaN NaN \n",
"10877 NaN NaN \n",
"12291 NaN NaN \n",
"13231 NaN NaN \n",
"13839 NaN NaN \n",
"13975 NaN NaN \n",
"14105 NaN NaN \n",
"14173 NaN NaN \n",
"14561 NaN NaN \n",
"15815 NaN NaN \n",
"15894 NaN NaN \n",
"15928 NaN NaN \n",
"19882 NaN NaN \n",
"20227 NaN NaN \n",
"20823 NaN NaN \n",
"20917 NaN NaN \n",
"21975 NaN NaN \n",
"... ... ... \n",
"152707 NaN NaN \n",
"155048 NaN NaN \n",
"158183 NaN NaN \n",
"161937 NaN NaN \n",
"162329 NaN NaN \n",
"163634 NaN NaN \n",
"163781 NaN NaN \n",
"164961 NaN NaN \n",
"165854 NaN NaN \n",
"166107 NaN NaN \n",
"166301 NaN NaN \n",
"166464 NaN NaN \n",
"166557 NaN NaN \n",
"167304 NaN NaN \n",
"168706 NaN NaN \n",
"171222 NaN NaN \n",
"171224 NaN NaN \n",
"171226 NaN NaN \n",
"171228 NaN NaN \n",
"171232 NaN NaN \n",
"171234 NaN NaN \n",
"171236 NaN NaN \n",
"172725 NaN NaN \n",
"173646 NaN NaN \n",
"175473 NaN NaN \n",
"175627 NaN NaN \n",
"176100 NaN NaN \n",
"176213 NaN NaN \n",
"176750 NaN NaN \n",
"178726 NaN NaN \n",
"\n",
" ball_recovery_offensive ball_recovery_recovery_failure \\\n",
"204 NaN NaN \n",
"749 NaN NaN \n",
"1651 NaN NaN \n",
"2741 NaN NaN \n",
"3890 NaN NaN \n",
"4594 NaN NaN \n",
"4647 NaN NaN \n",
"4784 NaN NaN \n",
"4918 NaN NaN \n",
"6271 NaN NaN \n",
"7406 NaN NaN \n",
"7924 NaN NaN \n",
"9525 NaN NaN \n",
"10606 NaN NaN \n",
"10877 NaN NaN \n",
"12291 NaN NaN \n",
"13231 NaN NaN \n",
"13839 NaN NaN \n",
"13975 NaN NaN \n",
"14105 NaN NaN \n",
"14173 NaN NaN \n",
"14561 NaN NaN \n",
"15815 NaN NaN \n",
"15894 NaN NaN \n",
"15928 NaN NaN \n",
"19882 NaN NaN \n",
"20227 NaN NaN \n",
"20823 NaN NaN \n",
"20917 NaN NaN \n",
"21975 NaN NaN \n",
"... ... ... \n",
"152707 NaN NaN \n",
"155048 NaN NaN \n",
"158183 NaN NaN \n",
"161937 NaN NaN \n",
"162329 NaN NaN \n",
"163634 NaN NaN \n",
"163781 NaN NaN \n",
"164961 NaN NaN \n",
"165854 NaN NaN \n",
"166107 NaN NaN \n",
"166301 NaN NaN \n",
"166464 NaN NaN \n",
"166557 NaN NaN \n",
"167304 NaN NaN \n",
"168706 NaN NaN \n",
"171222 NaN NaN \n",
"171224 NaN NaN \n",
"171226 NaN NaN \n",
"171228 NaN NaN \n",
"171232 NaN NaN \n",
"171234 NaN NaN \n",
"171236 NaN NaN \n",
"172725 NaN NaN \n",
"173646 NaN NaN \n",
"175473 NaN NaN \n",
"175627 NaN NaN \n",
"176100 NaN NaN \n",
"176213 NaN NaN \n",
"176750 NaN NaN \n",
"178726 NaN NaN \n",
"\n",
" block_deflection dribble_nutmeg dribble_outcome_id \\\n",
"204 NaN NaN NaN \n",
"749 NaN NaN NaN \n",
"1651 NaN NaN NaN \n",
"2741 NaN NaN NaN \n",
"3890 NaN NaN NaN \n",
"4594 NaN NaN NaN \n",
"4647 NaN NaN NaN \n",
"4784 NaN NaN NaN \n",
"4918 NaN NaN NaN \n",
"6271 NaN NaN NaN \n",
"7406 NaN NaN NaN \n",
"7924 NaN NaN NaN \n",
"9525 NaN NaN NaN \n",
"10606 NaN NaN NaN \n",
"10877 NaN NaN NaN \n",
"12291 NaN NaN NaN \n",
"13231 NaN NaN NaN \n",
"13839 NaN NaN NaN \n",
"13975 NaN NaN NaN \n",
"14105 NaN NaN NaN \n",
"14173 NaN NaN NaN \n",
"14561 NaN NaN NaN \n",
"15815 NaN NaN NaN \n",
"15894 NaN NaN NaN \n",
"15928 NaN NaN NaN \n",
"19882 NaN NaN NaN \n",
"20227 NaN NaN NaN \n",
"20823 NaN NaN NaN \n",
"20917 NaN NaN NaN \n",
"21975 NaN NaN NaN \n",
"... ... ... ... \n",
"152707 NaN NaN NaN \n",
"155048 NaN NaN NaN \n",
"158183 NaN NaN NaN \n",
"161937 NaN NaN NaN \n",
"162329 NaN NaN NaN \n",
"163634 NaN NaN NaN \n",
"163781 NaN NaN NaN \n",
"164961 NaN NaN NaN \n",
"165854 NaN NaN NaN \n",
"166107 NaN NaN NaN \n",
"166301 NaN NaN NaN \n",
"166464 NaN NaN NaN \n",
"166557 NaN NaN NaN \n",
"167304 NaN NaN NaN \n",
"168706 NaN NaN NaN \n",
"171222 NaN NaN NaN \n",
"171224 NaN NaN NaN \n",
"171226 NaN NaN NaN \n",
"171228 NaN NaN NaN \n",
"171232 NaN NaN NaN \n",
"171234 NaN NaN NaN \n",
"171236 NaN NaN NaN \n",
"172725 NaN NaN NaN \n",
"173646 NaN NaN NaN \n",
"175473 NaN NaN NaN \n",
"175627 NaN NaN NaN \n",
"176100 NaN NaN NaN \n",
"176213 NaN NaN NaN \n",
"176750 NaN NaN NaN \n",
"178726 NaN NaN NaN \n",
"\n",
" dribble_outcome_name ... pass_miscommunication shot_aerial_won \\\n",
"204 NaN ... NaN NaN \n",
"749 NaN ... NaN NaN \n",
"1651 NaN ... NaN NaN \n",
"2741 NaN ... NaN NaN \n",
"3890 NaN ... NaN NaN \n",
"4594 NaN ... NaN NaN \n",
"4647 NaN ... NaN NaN \n",
"4784 NaN ... NaN True \n",
"4918 NaN ... NaN NaN \n",
"6271 NaN ... NaN NaN \n",
"7406 NaN ... NaN NaN \n",
"7924 NaN ... NaN NaN \n",
"9525 NaN ... NaN NaN \n",
"10606 NaN ... NaN NaN \n",
"10877 NaN ... NaN NaN \n",
"12291 NaN ... NaN NaN \n",
"13231 NaN ... NaN NaN \n",
"13839 NaN ... NaN NaN \n",
"13975 NaN ... NaN NaN \n",
"14105 NaN ... NaN NaN \n",
"14173 NaN ... NaN NaN \n",
"14561 NaN ... NaN NaN \n",
"15815 NaN ... NaN NaN \n",
"15894 NaN ... NaN NaN \n",
"15928 NaN ... NaN NaN \n",
"19882 NaN ... NaN NaN \n",
"20227 NaN ... NaN NaN \n",
"20823 NaN ... NaN NaN \n",
"20917 NaN ... NaN NaN \n",
"21975 NaN ... NaN NaN \n",
"... ... ... ... ... \n",
"152707 NaN ... NaN NaN \n",
"155048 NaN ... NaN NaN \n",
"158183 NaN ... NaN NaN \n",
"161937 NaN ... NaN True \n",
"162329 NaN ... NaN NaN \n",
"163634 NaN ... NaN NaN \n",
"163781 NaN ... NaN NaN \n",
"164961 NaN ... NaN NaN \n",
"165854 NaN ... NaN NaN \n",
"166107 NaN ... NaN NaN \n",
"166301 NaN ... NaN NaN \n",
"166464 NaN ... NaN NaN \n",
"166557 NaN ... NaN NaN \n",
"167304 NaN ... NaN NaN \n",
"168706 NaN ... NaN NaN \n",
"171222 NaN ... NaN NaN \n",
"171224 NaN ... NaN NaN \n",
"171226 NaN ... NaN NaN \n",
"171228 NaN ... NaN NaN \n",
"171232 NaN ... NaN NaN \n",
"171234 NaN ... NaN NaN \n",
"171236 NaN ... NaN NaN \n",
"172725 NaN ... NaN NaN \n",
"173646 NaN ... NaN NaN \n",
"175473 NaN ... NaN NaN \n",
"175627 NaN ... NaN NaN \n",
"176100 NaN ... NaN NaN \n",
"176213 NaN ... NaN True \n",
"176750 NaN ... NaN NaN \n",
"178726 NaN ... NaN NaN \n",
"\n",
" shot_open_goal 50_50_outcome_id 50_50_outcome_name block_offensive \\\n",
"204 NaN NaN NaN NaN \n",
"749 NaN NaN NaN NaN \n",
"1651 NaN NaN NaN NaN \n",
"2741 NaN NaN NaN NaN \n",
"3890 NaN NaN NaN NaN \n",
"4594 True NaN NaN NaN \n",
"4647 NaN NaN NaN NaN \n",
"4784 NaN NaN NaN NaN \n",
"4918 NaN NaN NaN NaN \n",
"6271 NaN NaN NaN NaN \n",
"7406 NaN NaN NaN NaN \n",
"7924 NaN NaN NaN NaN \n",
"9525 NaN NaN NaN NaN \n",
"10606 NaN NaN NaN NaN \n",
"10877 NaN NaN NaN NaN \n",
"12291 NaN NaN NaN NaN \n",
"13231 NaN NaN NaN NaN \n",
"13839 NaN NaN NaN NaN \n",
"13975 NaN NaN NaN NaN \n",
"14105 NaN NaN NaN NaN \n",
"14173 NaN NaN NaN NaN \n",
"14561 NaN NaN NaN NaN \n",
"15815 NaN NaN NaN NaN \n",
"15894 NaN NaN NaN NaN \n",
"15928 NaN NaN NaN NaN \n",
"19882 NaN NaN NaN NaN \n",
"20227 NaN NaN NaN NaN \n",
"20823 NaN NaN NaN NaN \n",
"20917 NaN NaN NaN NaN \n",
"21975 NaN NaN NaN NaN \n",
"... ... ... ... ... \n",
"152707 True NaN NaN NaN \n",
"155048 NaN NaN NaN NaN \n",
"158183 NaN NaN NaN NaN \n",
"161937 NaN NaN NaN NaN \n",
"162329 NaN NaN NaN NaN \n",
"163634 NaN NaN NaN NaN \n",
"163781 NaN NaN NaN NaN \n",
"164961 NaN NaN NaN NaN \n",
"165854 NaN NaN NaN NaN \n",
"166107 NaN NaN NaN NaN \n",
"166301 NaN NaN NaN NaN \n",
"166464 NaN NaN NaN NaN \n",
"166557 NaN NaN NaN NaN \n",
"167304 NaN NaN NaN NaN \n",
"168706 NaN NaN NaN NaN \n",
"171222 NaN NaN NaN NaN \n",
"171224 NaN NaN NaN NaN \n",
"171226 NaN NaN NaN NaN \n",
"171228 NaN NaN NaN NaN \n",
"171232 NaN NaN NaN NaN \n",
"171234 NaN NaN NaN NaN \n",
"171236 NaN NaN NaN NaN \n",
"172725 True NaN NaN NaN \n",
"173646 True NaN NaN NaN \n",
"175473 NaN NaN NaN NaN \n",
"175627 NaN NaN NaN NaN \n",
"176100 NaN NaN NaN NaN \n",
"176213 NaN NaN NaN NaN \n",
"176750 NaN NaN NaN NaN \n",
"178726 NaN NaN NaN NaN \n",
"\n",
" miscontrol_aerial_won foul_committed_penalty shot_deflected \\\n",
"204 NaN NaN NaN \n",
"749 NaN NaN NaN \n",
"1651 NaN NaN NaN \n",
"2741 NaN NaN NaN \n",
"3890 NaN NaN NaN \n",
"4594 NaN NaN NaN \n",
"4647 NaN NaN NaN \n",
"4784 NaN NaN NaN \n",
"4918 NaN NaN NaN \n",
"6271 NaN NaN NaN \n",
"7406 NaN NaN NaN \n",
"7924 NaN NaN NaN \n",
"9525 NaN NaN NaN \n",
"10606 NaN NaN NaN \n",
"10877 NaN NaN True \n",
"12291 NaN NaN NaN \n",
"13231 NaN NaN NaN \n",
"13839 NaN NaN NaN \n",
"13975 NaN NaN NaN \n",
"14105 NaN NaN NaN \n",
"14173 NaN NaN NaN \n",
"14561 NaN NaN NaN \n",
"15815 NaN NaN NaN \n",
"15894 NaN NaN True \n",
"15928 NaN NaN NaN \n",
"19882 NaN NaN NaN \n",
"20227 NaN NaN NaN \n",
"20823 NaN NaN NaN \n",
"20917 NaN NaN NaN \n",
"21975 NaN NaN NaN \n",
"... ... ... ... \n",
"152707 NaN NaN NaN \n",
"155048 NaN NaN NaN \n",
"158183 NaN NaN NaN \n",
"161937 NaN NaN NaN \n",
"162329 NaN NaN NaN \n",
"163634 NaN NaN NaN \n",
"163781 NaN NaN NaN \n",
"164961 NaN NaN NaN \n",
"165854 NaN NaN NaN \n",
"166107 NaN NaN NaN \n",
"166301 NaN NaN NaN \n",
"166464 NaN NaN NaN \n",
"166557 NaN NaN NaN \n",
"167304 NaN NaN NaN \n",
"168706 NaN NaN NaN \n",
"171222 NaN NaN NaN \n",
"171224 NaN NaN NaN \n",
"171226 NaN NaN NaN \n",
"171228 NaN NaN NaN \n",
"171232 NaN NaN NaN \n",
"171234 NaN NaN NaN \n",
"171236 NaN NaN NaN \n",
"172725 NaN NaN NaN \n",
"173646 NaN NaN NaN \n",
"175473 NaN NaN NaN \n",
"175627 NaN NaN NaN \n",
"176100 NaN NaN NaN \n",
"176213 NaN NaN NaN \n",
"176750 NaN NaN NaN \n",
"178726 NaN NaN True \n",
"\n",
" shot_redirect \n",
"204 NaN \n",
"749 NaN \n",
"1651 NaN \n",
"2741 NaN \n",
"3890 NaN \n",
"4594 NaN \n",
"4647 NaN \n",
"4784 NaN \n",
"4918 NaN \n",
"6271 NaN \n",
"7406 NaN \n",
"7924 NaN \n",
"9525 NaN \n",
"10606 NaN \n",
"10877 NaN \n",
"12291 NaN \n",
"13231 NaN \n",
"13839 NaN \n",
"13975 NaN \n",
"14105 NaN \n",
"14173 NaN \n",
"14561 NaN \n",
"15815 NaN \n",
"15894 NaN \n",
"15928 NaN \n",
"19882 NaN \n",
"20227 NaN \n",
"20823 NaN \n",
"20917 NaN \n",
"21975 NaN \n",
"... ... \n",
"152707 NaN \n",
"155048 NaN \n",
"158183 NaN \n",
"161937 NaN \n",
"162329 NaN \n",
"163634 NaN \n",
"163781 NaN \n",
"164961 NaN \n",
"165854 NaN \n",
"166107 True \n",
"166301 NaN \n",
"166464 NaN \n",
"166557 NaN \n",
"167304 NaN \n",
"168706 NaN \n",
"171222 NaN \n",
"171224 NaN \n",
"171226 NaN \n",
"171228 NaN \n",
"171232 NaN \n",
"171234 NaN \n",
"171236 NaN \n",
"172725 NaN \n",
"173646 NaN \n",
"175473 NaN \n",
"175627 NaN \n",
"176100 NaN \n",
"176213 NaN \n",
"176750 NaN \n",
"178726 NaN \n",
"\n",
"[200 rows x 118 columns]"
]
},
"execution_count": 32,
"metadata": {},
"output_type": "execute_result"
}
],
"source": [
"d = df.query('shot_outcome_id == 97')\n",
"d"
]
},
{
"cell_type": "code",
"execution_count": 3,
"metadata": {},
"outputs": [
{
"data": {
"text/html": [
"<div>\n",
"<style scoped>\n",
" .dataframe tbody tr th:only-of-type {\n",
" vertical-align: middle;\n",
" }\n",
"\n",
" .dataframe tbody tr th {\n",
" vertical-align: top;\n",
" }\n",
"\n",
" .dataframe thead th {\n",
" text-align: right;\n",
" }\n",
"</style>\n",
"<table border=\"1\" class=\"dataframe\">\n",
" <thead>\n",
" <tr style=\"text-align: right;\">\n",
" <th></th>\n",
" <th>id</th>\n",
" <th>period</th>\n",
" <th>timestamp</th>\n",
" <th>location</th>\n",
" <th>pass_end_location</th>\n",
" <th>pass_recipient_name</th>\n",
" </tr>\n",
" </thead>\n",
" <tbody>\n",
" <tr>\n",
" <th>4</th>\n",
" <td>eea20658-0e9f-484a-90d3-dccdc589d81f</td>\n",
" <td>1</td>\n",
" <td>00:00:00.187</td>\n",
" <td>[60.0, 40.0]</td>\n",
" <td>[49.0, 35.0]</td>\n",
" <td>Toni Kroos</td>\n",
" </tr>\n",
" <tr>\n",
" <th>10</th>\n",
" <td>ad723dee-c477-4604-970a-48f6f3e54e45</td>\n",
" <td>1</td>\n",
" <td>00:00:04.200</td>\n",
" <td>[55.0, 43.0]</td>\n",
" <td>[37.0, 59.0]</td>\n",
" <td>Niklas Süle</td>\n",
" </tr>\n",
" <tr>\n",
" <th>112</th>\n",
" <td>89cd84d7-c140-4322-9d13-1cd4abd61829</td>\n",
" <td>1</td>\n",
" <td>00:02:53.600</td>\n",
" <td>[65.0, 23.0]</td>\n",
" <td>[71.0, 27.0]</td>\n",
" <td>Marco Reus</td>\n",
" </tr>\n",
" <tr>\n",
" <th>129</th>\n",
" <td>f189456f-9790-468f-937c-251068dfb181</td>\n",
" <td>1</td>\n",
" <td>00:03:03.517</td>\n",
" <td>[60.0, 25.0]</td>\n",
" <td>[56.0, 38.0]</td>\n",
" <td>Sami Khedira</td>\n",
" </tr>\n",
" <tr>\n",
" <th>143</th>\n",
" <td>408b675d-cbcb-4edd-baff-32bf2c93107d</td>\n",
" <td>1</td>\n",
" <td>00:03:15.080</td>\n",
" <td>[67.0, 45.0]</td>\n",
" <td>[56.0, 32.0]</td>\n",
" <td>Toni Kroos</td>\n",
" </tr>\n",
" </tbody>\n",
"</table>\n",
"</div>"
],
"text/plain": [
" id period timestamp location \\\n",
"4 eea20658-0e9f-484a-90d3-dccdc589d81f 1 00:00:00.187 [60.0, 40.0] \n",
"10 ad723dee-c477-4604-970a-48f6f3e54e45 1 00:00:04.200 [55.0, 43.0] \n",
"112 89cd84d7-c140-4322-9d13-1cd4abd61829 1 00:02:53.600 [65.0, 23.0] \n",
"129 f189456f-9790-468f-937c-251068dfb181 1 00:03:03.517 [60.0, 25.0] \n",
"143 408b675d-cbcb-4edd-baff-32bf2c93107d 1 00:03:15.080 [67.0, 45.0] \n",
"\n",
" pass_end_location pass_recipient_name \n",
"4 [49.0, 35.0] Toni Kroos \n",
"10 [37.0, 59.0] Niklas Süle \n",
"112 [71.0, 27.0] Marco Reus \n",
"129 [56.0, 38.0] Sami Khedira \n",
"143 [56.0, 32.0] Toni Kroos "
]
},
"execution_count": 3,
"metadata": {},
"output_type": "execute_result"
}
],
"source": [
"ozil_pass = df[(df.type_name == 'Pass') & (df.team_name == 'Germany') & (df.player_name == 'Mesut Ãzil') ]\n",
"pass_column = [i for i in df.columns if i.startswith(\"pass\")]\n",
"ozil_pass = ozil_pass[[\"id\", \"period\", \"timestamp\", \"location\", \"pass_end_location\", \"pass_recipient_name\"]]\n",
"ozil_pass.head()"
]
},
{
"cell_type": "code",
"execution_count": 4,
"metadata": {},
"outputs": [],
"source": [
"def draw_pitch(ax):\n",
" # focus on only half of the pitch\n",
" #Pitch Outline & Centre Line\n",
" Pitch = Rectangle([0,0], width = 120, height = 80, fill = False)\n",
" #Left, Right Penalty Area and midline\n",
" LeftPenalty = Rectangle([0,22.3], width = 14.6, height = 35.3, fill = False)\n",
" RightPenalty = Rectangle([105.4,22.3], width = 14.6, height = 35.3, fill = False)\n",
" midline = ConnectionPatch([60,0], [60,80], \"data\", \"data\")\n",
"\n",
" #Left, Right 6-yard Box\n",
" LeftSixYard = Rectangle([0,32], width = 4.9, height = 16, fill = False)\n",
" RightSixYard = Rectangle([115.1,32], width = 4.9, height = 16, fill = False)\n",
"\n",
"\n",
" #Prepare Circles\n",
" centreCircle = plt.Circle((60,40),8.1,color=\"black\", fill = False)\n",
" centreSpot = plt.Circle((60,40),0.71,color=\"black\")\n",
" #Penalty spots and Arcs around penalty boxes\n",
" leftPenSpot = plt.Circle((9.7,40),0.71,color=\"black\")\n",
" rightPenSpot = plt.Circle((110.3,40),0.71,color=\"black\")\n",
" leftArc = Arc((9.7,40),height=16.2,width=16.2,angle=0,theta1=310,theta2=50,color=\"black\")\n",
" rightArc = Arc((110.3,40),height=16.2,width=16.2,angle=0,theta1=130,theta2=230,color=\"black\")\n",
" \n",
" element = [Pitch, LeftPenalty, RightPenalty, midline, LeftSixYard, RightSixYard, centreCircle, \n",
" centreSpot, rightPenSpot, leftPenSpot, leftArc, rightArc]\n",
" for i in element:\n",
" ax.add_patch(i)"
]
},
{
"cell_type": "code",
"execution_count": 5,
"metadata": {},
"outputs": [
{
"data": {
"image/png": "iVBORw0KGgoAAAANSUhEUgAAAawAAAEyCAYAAACmpOSfAAAABHNCSVQICAgIfAhkiAAAAAlwSFlzAAALEgAACxIB0t1+/AAAADl0RVh0U29mdHdhcmUAbWF0cGxvdGxpYiB2ZXJzaW9uIDMuMC4yLCBodHRwOi8vbWF0cGxvdGxpYi5vcmcvOIA7rQAAIABJREFUeJzsnXd4VNXzxt9LKNJrABGB0JtIExCRItJBqgIqAiJKE1RUsKP4o9gVEEPvLXTpTToEQgcpoRMIECCk953fHy/73ZItdzebbCLn8zx5wt695ezdcObOnHdmNBGBQqFQKBSZnWzeHoBCoVAoFHpQBkuhUCgUWQJlsBQKhUKRJVAGS6FQKBRZAmWwFAqFQpElUAZLoVAoFFkCZbAUCoVCkSVQBkuhUCgUWQJlsBQKhUKRJciekRcrVqyYlCtXLiMvqVAoFIpMzJEjR+6JiK+efTPUYJUrVw5BQUEZeUmFQqFQZGI0Tbumd18VElQoFApFlkCXwdI07UNN085omnZa07TFmqY9oWman6ZpgZqmBWuatlTTtJzpPViFQqFQPL44NViapj0FYDiA+iJSE4APgF4AJgL4VUQqAQgHMCA9B6pQKBSKxxu9IcHsAHJrmpYdQB4AoQBeArD80ftzAXTx/PAUCoVCoSBORRciclPTtJ8AXAcQB2ALgCMAHopI8qPdQgA8Zet4TdPeBfAuAJQpU8bmNcqVK4dr13SvuykUCoUii1G2bFlcvXo1TedwarA0TSsMoDMAPwAPAQQAaGdjV5udIEVkGoBpAFC/fn2b+1y7dg2qkaTicWHOnDnYuXMn5syZ4+2hKBQZhqZpaT6HnpDgywCuiEiYiCQBWAmgMYBCj0KEAFAawK00j0ahUCgUCjvoMVjXATTSNC2PRhPZEsC/AP4B0OPRPn0BrEmfISoUCoVCocNgiUggKK44CuDUo2OmARgF4CNN0y4CKApgZjqOU6FQKBSPOboqXYjINwC+sdp8GUADj49IoVA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9UaNoIF01wCkpqdemDAYm3D/9NEOWFy/aNlgrV7Ki/Pbt9gUZs2ZxTJkl71GJLhRZmmzZqGD64w+2dFD890lKshRbpAfWHtb9+0wirlKFdfVy5GAXAREmshcr5v6T/5YtVAdOmqT/mORkqmVr1KC835wvvmDR3jlz+P/j8GHLST4qCnj7beDjjxl69PGxLcVPSck8YguAn/nuXc8lDQPKYCm8QOnSNFh9+rAIquK/zbp19HTSq0Hi7duc1M0VegUKAB060JPKlQsYMQIYPz7tcvbwcIYYZ80CChd2vn9iokn5N2sWMGUK74eR6dPZ9Xj1alaNB1In2c6axZYkvXvzc9rrkBwQQEO9cSNw7px7n8+ThIYyfcHdPDdbKIOl8Aq9ejGJ1NWmcoqsR3qKLQCGA597zlJkYKy+HhbG2oW5cplk9GkxWEOHspiss+Pj42mcKlakQZozh7lV5kKPzZuBr74CNmygx2ePESMonZ82jUYyZ07b+y1ZwnzH0FDWRixblv/P/gs1BI04VQlqmlYFwFKzTeUBfA1g3qPt5QBcBfCaiIR7dniK/zJTplCGbCzhpPjvcfUqQ1wrV6bfNezlX7VuzXqB/frRk1++nP2v9u+nfNxVli6lGtFRwnNMDNfOfvqJsvLly20nM588yQjDqlX6crcmTKChjI5mknJyMn8HB3NN7OhRVts4fpweZ8mS/H3qlOM+X+mJpwUXgA4PS0TOi0htEakNoB6AWACrAIwGsF1EKgHY/ui1QqGbIkX4VPjwobdHokgvZswA3nwz/cQWgP0KF999Z8qP6tWLf2sHDjA0WaiQa9e4dQsYPpzrUHnypH4/MpIhx/LleY0NG7jOZWtcN2+yCPCkSfT+7GEwcNJ
"text/plain": [
"<Figure size 504x360 with 1 Axes>"
]
},
"metadata": {
"needs_background": "light"
},
"output_type": "display_data"
}
],
"source": [
"fig=plt.figure() #set up the figures\n",
"fig.set_size_inches(7, 5)\n",
"ax=fig.add_subplot(1,1,1)\n",
"draw_pitch(ax) #overlay our different objects on the pitch\n",
"plt.ylim(-2, 82)\n",
"plt.xlim(-2, 122)\n",
"#plt.plot(x_axis,y_axis,'ro')\n",
"#plt.plot(x,y,'bo')\n",
"#plt.axis('off')\n",
"\n",
"for i in range(len(ozil_pass)):\n",
" # annotate draw an arrow from a current position to pass_end_location\n",
" ax.annotate(\"\", xy = (ozil_pass.iloc[i]['pass_end_location'][0], ozil_pass.iloc[i]['pass_end_location'][1]), xycoords = 'data',\n",
" xytext = (ozil_pass.iloc[i]['location'][0], ozil_pass.iloc[i]['location'][1]), textcoords = 'data',\n",
" arrowprops=dict(arrowstyle=\"->\",connectionstyle=\"arc3\", color = \"blue\"),)\n",
"plt.show()"
]
},
{
"cell_type": "code",
"execution_count": 10,
"metadata": {},
"outputs": [
{
"data": {
"image/png": "iVBORw0KGgoAAAANSUhEUgAAAbQAAAEyCAYAAACS3SWDAAAABHNCSVQICAgIfAhkiAAAAAlwSFlzAAALEgAACxIB0t1+/AAAADl0RVh0U29mdHdhcmUAbWF0cGxvdGxpYiB2ZXJzaW9uIDMuMC4yLCBodHRwOi8vbWF0cGxvdGxpYi5vcmcvOIA7rQAAIABJREFUeJztnX/MZuVZ578XjGVmdJthGKnsvLDQdeJuJbpDJixrN6YpNUIlTP9oDW5TxxYzMekqGjcCkmyziSY0GmvN1m4mpRY3pFixLsStWgQas3+AHSjSHxQ7SysMjIWJpZqdGZH12j+e8yyHZ86P+8d1n3Pf9/l+ksm87/Occ+77vOd9z+e5rvu67yOqCkIIIaR0zpm7A4QQQogFFBohhJAqoNAIIYRUAYVGCCGkCig0QgghVUChEUIIqQIKjRBCSBVQaIQQQqqAQiOEEFIF2+buQJsLLrhAL7nkkrm7QQghJCMef/zxk6r63WPbZSW0Sy65BA8++ODc3SCEEJIRu3fv/muX7ZhyJIQQUgUUGiGEkCqg0AghhFQBhUYIIaQKKDRCCCFVQKERQgipAgqNEEJIFTgLTUQ+LiIviMiXWq/tFpH7ReRrzf/nN6+LiPyWiBwTkSdE5IoUnSeEEELW+ERonwBwzcZrtwB4QFX3AXig+R4ArgWwr/l3GMBH47pJCC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PcJ07FthorEtV+MENNDoZHsmEJmc4osRmJ9ffIdS7OOyrr65Cu3TaEMFYOEpBhLSDsyOouDQiNOTJV2DJWZtXisxRgrsb4+hRSFxMhsTGQ
"text/plain": [
"<Figure size 504x360 with 1 Axes>"
]
},
"metadata": {
"needs_background": "light"
},
"output_type": "display_data"
}
],
"source": [
"fig, ax = plt.subplots()\n",
"fig.set_size_inches(7, 5)\n",
"\n",
"x_coord = [i[0] for i in ozil_pass[\"location\"]]\n",
"y_coord = [i[1] for i in ozil_pass[\"location\"]]\n",
"\n",
"#shades: give us the heat map we desire\n",
"# n_levels: draw more lines, the larger n, the more blurry it looks\n",
"sns.kdeplot(x_coord, y_coord, shade = \"True\", color = \"black\", n_levels = 30)\n",
"plt.show()"
]
}
],
"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.6.8"
}
},
"nbformat": 4,
"nbformat_minor": 2
}