mne-python icon indicating copy to clipboard operation
mne-python copied to clipboard

Add cmap to animate_topomap

Open withmywoessner opened this issue 1 year ago • 3 comments

Describe the new feature or enhancement

I would like to add a cmap parameter to animate_topomap. Currently, plot_topomap includes this parameter so I would like to update it to match plot_topomap.

Describe your proposed implementation

Add a new parameter cmap to animate_topomap

Describe possible alternatives

Maybe I can just add a tutorial to do this with existing matplotlib api??

Additional context

There may also be some other parameters I can add to bring the functionality closer to plot_topomap.

withmywoessner avatar Feb 05 '24 08:02 withmywoessner

Yes feel free to add it. You can add just that or more params if you need to for your use case (or want to for completeness). I don't think animate_topomap has kept up with all options.

larsoner avatar Feb 05 '24 14:02 larsoner

Is there some way I could accomplish this using **kwargs so it doesn't have to be updated each time something is added to animate_topomap? Thanks!

withmywoessner avatar Feb 05 '24 15:02 withmywoessner

In principle yes (the syntax works) but in practice we avoid doing it because it can hide problems if you're not careful and forces people to look for docs elsewhere. Instead we prefer to duplicate and use docdict for the doc strings. It's more work for us as maintainers but nicer for users.

larsoner avatar Feb 05 '24 15:02 larsoner