Skip to content

Instantly share code, notes, and snippets.

@rsalaza4
Created January 17, 2025 16:00
Show Gist options
  • Save rsalaza4/a7dbe7c9432d60bda8065bf6cfa845f7 to your computer and use it in GitHub Desktop.
Save rsalaza4/a7dbe7c9432d60bda8065bf6cfa845f7 to your computer and use it in GitHub Desktop.
# Create heatmap
sns.heatmap(minutes_df.groupby([minutes_df['Business Date'].dt.date, minutes_df['Business Date'].dt.strftime('%H:00')])
['Orders'].mean()
.rename_axis(index=['Date','Hour'])
.unstack(level=0),
cmap='coolwarm'
)
# Add title
plt.title('Customers in Queue Over Time')
# Show figure
plt.show()
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment