0

Can someone point me to a list of acceptable kde keyword arguments? I am aware of a few, e.g.:

kde_kws={"linewidth": 4, 'linestyle':'--', "color": "k", "label": "KDE"}
Cactus Philosopher
  • 804
  • 2
  • 12
  • 25
  • 1
    See `kwargs` here: https://matplotlib.org/3.1.1/api/_as_gen/matplotlib.pyplot.plot.html – ayhan Oct 13 '19 at 06:28
  • I'm specifically trying to modify the edge color of the kde lines. I can't find this keyword, am I missing something? – Cactus Philosopher Oct 13 '19 at 06:32
  • What do you mean by the edge color? – ayhan Oct 13 '19 at 06:37
  • Like this: https://stackoverflow.com/questions/12729529/can-i-give-a-border-outline-to-a-line-in-matplotlib-plot-function – Cactus Philosopher Oct 13 '19 at 06:41
  • 1
    You should be able to pass `path_effects` like the answer in that link does: `sns.distplot(x, kde_kws={'color':'k', 'lw':2, 'path_effects':[pe.Stroke(linewidth=5, foreground='g'), pe.Normal()]})` – ayhan Oct 13 '19 at 06:54

1 Answers1

1

You can find the kde keyword arguments here: https://seaborn.pydata.org/generated/seaborn.kdeplot.html

What you suggested as kde keyword arguments are actually

Other keyword arguments are passed to plt.plot() or plt.contour{f} depending on whether a univariate or bivariate plot is being drawn.

So if you're looking for the keyword arguments of plt.plot or plt.contour, look them up on matplotlib documentation.

https://matplotlib.org/3.1.1/api/_as_gen/matplotlib.pyplot.plot.html https://matplotlib.org/3.1.1/api/_as_gen/matplotlib.pyplot.contour.html

ba_ul
  • 2,049
  • 5
  • 22
  • 35