WMDRRG(3NCARG)

πŸ’– WMDRRG β€” bestie, we're plotting weather regions πŸ’–

okay so real talk: this is a page from the NCAR GRAPHICS manual, specifically the WMDRRG(3NCARG) entry. grab a snack, we're drawing maps πŸ—ΊοΈβœ¨


✨ NAME ✨

WMDRRG β€” plots weather map regions (the ones that say "snow", "rain", etc. on them 🧚) or, if you're feeling minimalist, solid regions indicating temperature zones.

✨ SYNOPSIS ✨

CALL WMDRRG(N,X,Y,ITYPE,NC,XC,YC)

πŸ¦‹ C-BINDING SYNOPSIS πŸ¦‹

for my C girlies, no cap, here's your glow-up:

#include <ncarg/gks.h>

void c_wmdrrg(int n, float *x, float *y, char *itype, int nc, float *xc,
float *yc)

🌸 DESCRIPTION 🌸

here's the whole cast, in order of appearance πŸ’…

  • N (Integer, Input) β€” the number of points you're supplying in the second and third arguments. like, how many points bestie, spill.
  • X (Real, Input) β€” the X coordinates (specified in world coordinates) of those N points. these are the control points of a spline curve that gets fitted to represent the region you're asking for. it's giving "trust the process" 🌈
  • Y (Real, Input) β€” same deal as X but for Y: the Y coordinates (specified in world coordinates) of the N points, and again these are the control points of the spline curve that will be fitted to represent the requested region. iconic duo fr fr 🫢
  • ITYPE (Character, Input) β€” tells the program what weather type to fill the region with, or a solid color. it's the whole vibe of your blob.

ITYPE can be one of:

  • 'T' for thunderstorms β›ˆοΈ
  • 'SH' for showers 🌦️
  • 'R' for rain β˜”
  • 'F' for flurries 🌨️
  • 'SN' for snow ❄️
  • 'I' for ice 🧊
  • 'INDEXnn' where the number "nn" denotes a color index for a solid fill 🎨
  • NC (Integer, input) β€” the clip switch, lowkey the most dramatic one. if NC is greater than 2, then the region resulting from the spline fit to ((X(I),Y(I)),I=1,N) will be clipped against the region in ((XC(I),YC(I)),I=1,NC). if no clipping is to be done, then set NC equal to 1. periodt.
  • XC (Real, Input) β€” the X coordinates (specified in world coordinates) of NC points that specify a clipping polygon for the region resulting from the spline fit to ((X(I),Y(I)),I=1,N), if NC is greater than 2. scissors, but make it coordinates βœ‚οΈ
  • YC (Real, Input) β€” the Y coordinates (specified in world coordinates) of NC points that specify a clipping polygon for the region resulting from the spline fit to ((X(I),Y(I)),I=1,N), if NC is greater than 2. matching half of the clipping polygon, we love a coordinated set πŸ’œ

πŸ’… USAGE πŸ’…

set the values for the appropriate internal parameters before calling WMDRRG, otherwise you will simply not get the region you wanted and that's so not the move. the internal parameters that control the appearance of regions are: COL and RHT. note them, bestie, they matter πŸ“

as mentioned above, the points specified in the X and Y arrays serve as control points for a spline curve that is fitted to the input polygon.

ok and this part is important: X(N) should equal X(1) and Y(N) should equal Y(1). yes, you close the loop. you come back home. no leaving your polygon open, it's giving unfinished business 😭

🌈 ACCESS 🌈

to use WMDRRG or c_wmdrrg, load the NCAR Graphics libraries ncarg, ncarg_gks, and ncarg_c β€” preferably in that order. in that order specifically, don't fight the order, the order ate πŸ’―

⭐ SEE ALSO ⭐

  • Online: wmap, wmdflt, wmgetc, wmgeti, wmgetr, wmsetc, wmseti, wmsetr, wmap_params
  • Hardcopy: WMAP - A Package for Producing Daily Weather Maps and Plotting Station Model Data

go read those next, iykyk πŸ“šβœ¨

Copyright (C) 1987-2009 University Corporation for Atmospheric Research The use of this Software is governed by a License Agreement.


and that's the whole page bestie πŸŽ€ this entry lived on the UNIX manual, dated January 1995, filed under WMDRRG(3NCARG). thank you for coming to my ted talk, go plot something gorgeous πŸŒΈπŸ’–