0

From How to set some xlim and ylim in Seaborn lmplot facetgrid I've find out that you can specify xlim by using

g = sns.relplot(data=df_weekday,
            x="date", y="battery/min", kind="scatter", hue="version")
g.set(xlim=('2019-07-16','2019-11-06'))

This works perfectly however can I add more parameters inside,

instead of calling plt.xticks(rotation=90) and other controls on each line I want to include all inside g.set().

Furthermore when I try to spread my graph by setting height=10, aspect=2 however it makes all the fonts too small and having graph without height, aspect makes my graph too squished.

I want to add height, aspect and change all fonts also inside g.set() if possible.

haneulkim
  • 4,406
  • 9
  • 38
  • 80
  • 1
    It's not possible to use `g.set()` for that. For the tick parameters you need to loop over the axes `for ax in g.axes:`. For the size of the plot, you need to specify `height` and `aspect` within the `relplot` call. – ImportanceOfBeingErnest Nov 13 '19 at 14:38
  • I like height and aspect however aspect messes up my font. I do not want to re-adjust my font with plt.font everytime. Is there another way? – haneulkim Nov 14 '19 at 02:25
  • In fact, neither height, nor aspect change the font. If you have a font of 10 pt set in the rcParams, it will be 10 pt always. It's probably that you perceive the font as being smaller because everything else grows bigger. – ImportanceOfBeingErnest Nov 14 '19 at 03:03
  • okay so only way to make font grow proportional to graph is just to set font larger in rcParams? – haneulkim Nov 14 '19 at 04:55

0 Answers0