Spaces:
Running
Running
Update app.py
Browse files
app.py
CHANGED
@@ -884,13 +884,13 @@ def server(input, output, session):
|
|
884 |
sns.lineplot(x=player_games_one.game,y=(player_games_one.rolling(last_games).sum()['TOI_pp']/player_games_one.rolling(last_games).sum()['pp_toi']),ax=axn,color='#648FFF',linewidth = 2,label='PP%',legend=False)
|
885 |
#
|
886 |
handles, labels = [ax5.get_legend_handles_labels()[0]+axn.get_legend_handles_labels()[0]]+[ax5.get_legend_handles_labels()[1]+axn.get_legend_handles_labels()[1]]
|
887 |
-
ax5.legend(handles, labels, fontsize=10,ncol=2,loc=9
|
888 |
|
889 |
sns.lineplot(x=player_games_one.game,y=player_games_one.rolling(last_games).mean()['Total Points'],ax=ax6,color='#FFB000',label='Points',linewidth = 2)
|
890 |
sns.lineplot(x=player_games_one.game,y=player_games_one.rolling(last_games).mean()['Total Points_pp'],ax=ax6,color='#648FFF',label='PP Points',linewidth = 2)
|
891 |
sns.lineplot(x=player_games_one.game,y=player_games_one.rolling(last_games).mean()['Goals'],ax=ax6,color='#DC267F',label='Goals',linewidth = 2)
|
892 |
sns.lineplot(x=player_games_one.game,y=player_games_one.rolling(last_games).mean()['Total Assists'],ax=ax6,color='#FE6100',label='Assists',linewidth = 2)
|
893 |
-
ax6.legend(fontsize=10,ncol=4,loc=9
|
894 |
ax6.xaxis.set_major_locator(MaxNLocator(integer=True))
|
895 |
ax6.set_xlim([last_games, np.max(player_games_one.game)])
|
896 |
ax6.set_ylim([0, round(max((player_games_one.rolling(last_games).mean().fillna(0)['Total Points'])+1)*2)/2])
|
|
|
884 |
sns.lineplot(x=player_games_one.game,y=(player_games_one.rolling(last_games).sum()['TOI_pp']/player_games_one.rolling(last_games).sum()['pp_toi']),ax=axn,color='#648FFF',linewidth = 2,label='PP%',legend=False)
|
885 |
#
|
886 |
handles, labels = [ax5.get_legend_handles_labels()[0]+axn.get_legend_handles_labels()[0]]+[ax5.get_legend_handles_labels()[1]+axn.get_legend_handles_labels()[1]]
|
887 |
+
ax5.legend(handles, labels, fontsize=10,ncol=2,loc=9)
|
888 |
|
889 |
sns.lineplot(x=player_games_one.game,y=player_games_one.rolling(last_games).mean()['Total Points'],ax=ax6,color='#FFB000',label='Points',linewidth = 2)
|
890 |
sns.lineplot(x=player_games_one.game,y=player_games_one.rolling(last_games).mean()['Total Points_pp'],ax=ax6,color='#648FFF',label='PP Points',linewidth = 2)
|
891 |
sns.lineplot(x=player_games_one.game,y=player_games_one.rolling(last_games).mean()['Goals'],ax=ax6,color='#DC267F',label='Goals',linewidth = 2)
|
892 |
sns.lineplot(x=player_games_one.game,y=player_games_one.rolling(last_games).mean()['Total Assists'],ax=ax6,color='#FE6100',label='Assists',linewidth = 2)
|
893 |
+
ax6.legend(fontsize=10,ncol=4,loc=9)
|
894 |
ax6.xaxis.set_major_locator(MaxNLocator(integer=True))
|
895 |
ax6.set_xlim([last_games, np.max(player_games_one.game)])
|
896 |
ax6.set_ylim([0, round(max((player_games_one.rolling(last_games).mean().fillna(0)['Total Points'])+1)*2)/2])
|