plotparallels()/plotmeridians() only support xoffset or yoffset not both and do not support horizontalalignment or verticalalignment
Nobody has claimed this yet.
Assessment
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Newbie friendliness
- 45/100
- Issue type
- Feature
- Clarity
- Mostly clear
- Activity status
- Stale
- Tech stack
- python
- Domain
- data-visualization
Research direction
Locate the implementations of plotparallels() and plotmeridians() and trace how xoffset, yoffset, and kwargs are handled. Verify the behavior with labels on both sides of the map: both offsets should work together, and horizontalalignment and verticalalignment should be accepted. Done means callers no longer need to modify the returned matplotlib objects for this positioning.
Written by the indexing model from the issue text.
Description
plotparallels() and plotmeridians() only support xoffset or yoffset not both.
plotparallels() and plotmeridians() do not support horizontalalignment or verticalalignment via kwargs as these are hard coded within Basemap.
I found both of these because I wanted the labels inside the map border with the parallels above the line at the right of the plot and the meridians to the right of the line at the bottom of the plot. I found a hack by altering the returned matplotlib objects:
meridians = bmap.drawmeridians(meridians,labels=[0,0,1,0],fontsize=10,
color='gray', yoffset=-abs(right-left)
for k, v in meridians.iteritems():
v[1][0].set_horizontalalignment('left')
This sets the label to the top but then moving them the size of the plot then setting horizontal alignment via returned matplotlib object.
- 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