SPC Outlook Plot Line Width? #2718
-
Hello, I'm experimenting with the SPC Outlook example code, and I was able to customize the US States/Counties line width, but cannot seem to figure out how to change the line width/style of the outlook lines itself. Any way to do this? Here's my code for the PlotGeometry/MapPanel portion of the program: # Initialize geometry plotting
otlk = PlotGeometry()
otlk.geometry = day1_outlook['geometry']
otlk.fill = day1_outlook['fill']
otlk.stroke = day1_outlook['stroke']
otlk.labels = day1_outlook['LABEL']
otlk.label_fontsize = 'large'
...
us_counties = MetPyMapFeature('us_counties', '20m', linewidth=0.2, facecolor='None', edgecolor='gray')
us_states = MetPyMapFeature('us_states', '20m', linewidth=1.5, facecolor='None', edgecolor='black')
panel = MapPanel()
panel.title = 'SPC Day 1 Categorical Convective Outlook (Valid ' + time_issued + 'Z - ' + time_expire + 'Z)\nData Processed In: ' + generatetime + 's — Graphic Generated: ' + now + ''
panel.plots = [otlk]
panel.area = [-120, -75, 25, 50]
panel.projection = 'lcc'
panel.layers = [us_counties, 'ocean', 'lakes', 'land', us_states, 'coastline', 'borders'] Any guidance/assistance is much appreciated! |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 3 replies
-
The options on
It doesn't appear we have any option for the stroke/line width. I can see adding it as I think given that last sentence, I lean to adding it. @dcamron @kgoebber any thoughts? |
Beta Was this translation helpful? Give feedback.
The options on
PlotGeometry
for controlling the appearance of the geometry (not the labels) are:stroke
- edgecolor for polygons, line color for linesmarker
- What symbol is used for pointsfill
- fill color for points/polygonsIt doesn't appear we have any option for the stroke/line width. I can see adding it as
stroke_width
, but I do hesitate a bit because I don't want to add attributes for every matplotlib option. On the other hand, we probably should add it since, as you noted, we do have the option for the map features.I think given that last sentence, I lean to adding it. @dcamron @kgoebber any thoughts?