Pass `locator` argument to matplotlib when calling `plot.contourf`
Nobody has claimed this yet.
- Dominant language
- Python
- Stars
- 4.2k
- Forks
- 1.4k
- Avg merge
- 2d 15h
- Merged PRs (30d)
- 14
Description
Is your feature request related to a problem? Please describe.
Everytime I have to do a contourf I need to call it from matplotlib directly because locator argument is not passed from xarray.plot.contourf to matplotlib.
Describe the solution you'd like
Being ds a xarray.DataArray, I want to have the behaviour described here when passing locator = ticker.LogLocator() to ds.plot.contourf.
Describe alternatives you've considered
I usually have to do plt.contourf(ds.dim_0,ds.dim_1,ds.values,locator = ticker.LogLocator()).
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start at xarray.plot.contourf and compare its arguments with matplotlib's contourf, focusing on the locator=ticker.LogLocator() example in the issue. Confirm how direct matplotlib calls handle the locator, then verify that the xarray plotting call accepts it and produces the same locator behavior.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- matplotlib, python
- Domain
- data-visualization
- Issue type
- Feature
- Difficulty
- 2/5
- Estimated time
- 1-3 hours
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 52/100