Skip to content

Instantly share code, notes, and snippets.

@masterdesky
Created April 15, 2025 10:12
Show Gist options
  • Save masterdesky/8ab467fd19d2160eb73f25b1a8fb459d to your computer and use it in GitHub Desktop.
Save masterdesky/8ab467fd19d2160eb73f25b1a8fb459d to your computer and use it in GitHub Desktop.
Configuration for the visual style of my educational plots in Python
# Initialize seaborn with custom settings
import matplotlib.pyplot as plt
import seaborn as sns
# Facecolor values from S. Conradi @S_Conradi/@profConradi
custom_settings = {
'figure.facecolor': '#f4f0e8',
'axes.facecolor': '#f4f0e8',
'axes.edgecolor': '0.7',
'axes.linewidth' : '2',
'grid.color': '0.7',
'grid.linestyle': 'none',
'grid.alpha': 0.6,
}
sns.set_theme(palette=sns.color_palette('deep', as_cmap=False),
rc=custom_settings)
plt.rcParams['text.usetex'] = False
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment