Mack's LoL Scout
Explain

Plotly: enough to be dangerous

Plotly is a chart factory: you hand it a dataframe, it hands you a figure. The best plotly debugging technique is checking your dataframe before you blame the chart.

TL;DR

  • Use Plotly Express (px) first. Don’t overbuild.
  • Always save with write_html so you can open/share.
  • If the plot is wrong, your dataframe is probably wrong.

The “save it to HTML” move

fig = px.bar(df, x='champion', y='games')
fig.write_html('reports/champ_pool.html')

The pre-plot checklist

  • Columns exist? (print df.columns)
  • Sorted for time plots? (print min/max, then sort)
  • No weird strings in numeric columns?

The one print that saves 30 minutes

print(df[['game_start', 'win']].head(10).to_string(index=False))