DHI/mikeio

Pass kwargs to plot.mesh

Opened this issue · 2 comments

Hi,

I am relatively new to the package so feel free to close if this functionality exists (if so, maybe incorporating into the docs would be helpful).

We should be able to pass kwargs to the matplotlib function that is being used by mikeio when using the plot methods.

For example, if I want to change the colors/line widths etc of a mesh in a dfsu, it might look like.

fig, axes = plt.subplots()
mds.geometry.plot.mesh()
collection = axes.get_children()[0]
collection.set(**kwargs)

but this could be:

mds.geometry.plot.mesh(**kwargs)

Hi @chrisawhitwell, would you like to submit a PR with your suggestion?

The place to start tweaking is

Please also add a test that showcases the functionality.

Hey @ecomodeller, Sure thing I will get to it when I find some time!