Matplotlib Example
Nobody has claimed this yet.
Assessment
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Newbie friendliness
- 35/100
- Issue type
- Documentation
- Clarity
- Mostly clear
- Activity status
- Stale
- Tech stack
- python
- Domain
- data-visualization, documentation
Research direction
Start with basemap/users/figures/plotprecip.py and compare its variables with the newer NetCDF file linked in the issue. Check the referenced Matplotlib issue for context, then update the sample so its data fields and units match the supported source and verify that the example runs.
Written by the indexing model from the issue text.
Description
Hello! ... I reported the following issue in the Matplotlib repo... and they said to bring it to your attention:
The Matplotlib Sample: "Plot Precip With Filled Contours"
https://matplotlib.org/basemap/users/examples.html
code source: https://matplotlib.org/basemap/users/figures/plotprecip.py
seems to be dated... I say "seems" because this is my first week of python! :)
Code for reproduction
The variables as specified in your code do not seem to exist:
latcorners = nc.variables['lat'][:]
loncorners = -nc.variables['lon'][:]
lon_0 = -nc.variables['true_lon'].getValue()
lat_0 = nc.variables['true_lat'].getValue()
I'm guessing because that data is from 2006 and something has changed since then :)
I have been failing with new data located here:
http://water.weather.gov/precip/downloads/2018/01/24/nws_precip_1day_20180124_conus.nc
surely there is a way for matplotlib to cull the information needed from the file? if not I figure I'll do the long math..
use your code located here
code source: https://matplotlib.org/basemap/users/figures/plotprecip.py
but also notice that not only are the lat lon variables present, your variable:
prcpvar = nc.variables['amountofprecip']
will need to be adjusted to prcpvar = nc.variables['observation']
and the units are now inches instead of mm.
Here is the issue I submitted to matplotlib:
https://github.com/matplotlib/matplotlib/issues/10318
- Dominant language
- Python
- Stars
- 817
- Forks
- 395
- PR merge metrics
- No merged PRs in 30d
Contributor guide
No contributing guide indexed for this repository
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.
More from matplotlib/basemap
-
Difficulty 2/5 1-3 hours Newbie friendliness 68/100
matplotlib/basemap#368 ·
-
Python 3.14 wheels Open
Difficulty 4/5 3-5 days Newbie friendliness 48/100
matplotlib/basemap#652 · 2 comments · 5 reactions ·
-
Difficulty 2/5 1-3 hours Newbie friendliness 45/100
matplotlib/basemap#649 · 2 reactions ·
-
Difficulty 5/5 Over a week Newbie friendliness 35/100
matplotlib/basemap#646 ·
-
Difficulty 2/5 1-3 hours Newbie friendliness 48/100
matplotlib/basemap#645 · 2 comments ·
All issues in matplotlib/basemap
Similar issues
-
documentation help wanted
Difficulty 2/5 1-3 hours Newbie friendliness 90/100
-
Difficulty 2/5 1-3 hours Newbie friendliness 90/100
simonw/sqlite-utils#872 ·
-
Difficulty 2/5 1-3 hours Newbie friendliness 88/100
-
Difficulty 2/5 1-3 hours Newbie friendliness 82/100
-
Difficulty 2/5 1-3 hours Newbie friendliness 78/100