Comment

Comment by static_noise

Here

https://matplotlib.org/api/pyplot_api.html#matplotlib.pyplot...

I count about 40 plus more which are not listed.

You surely could first make a dictionary or structure and fill it with these arguments. But then "kwargs" are just that, a dictionary.

I find the interface of the plot function pretty straightforward. There are a lot of options but it's pretty clear what they do and when to use them. Most often you use only some of them - but often different combinations. Splitting this up into multiple helper objects that need to be constructed and filled beforehand would turn the default one-liner into a ten-liner which is not better.

Discussion

Live from the official Hacker News API

A modern reader for Hacker News · SvelteKit + Skeleton