Last active
January 31, 2023 19:56
-
-
Save marcelmaatkamp/23af16aababf8efe5ce00c62573c8f80 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
--- | |
from sqlalchemy import create_engine | |
engine = create_engine('postgresql://postgres:postgres@postgres:5432/postgres', echo=False) | |
--- | |
import pandas as pd | |
with engine.connect() as connection: | |
df = pd.read_sql('ais', connection) | |
df | |
--- | |
import seaborn as sns | |
# Apply the default theme | |
sns.set_theme() | |
# Load an example dataset | |
tips = sns.load_dataset("tips") | |
# Create a visualization | |
sns.relplot( | |
data=df, | |
x="total_bill", y="tip", col="time", | |
hue="smoker", style="smoker", size="size", | |
) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment