Skip to content

Commit

Permalink
deploy: b0067ee
Browse files Browse the repository at this point in the history
  • Loading branch information
dcamron committed Jun 17, 2024
1 parent 5c8debf commit b503240
Show file tree
Hide file tree
Showing 55 changed files with 235 additions and 528 deletions.
6 changes: 3 additions & 3 deletions README.html
Original file line number Diff line number Diff line change
Expand Up @@ -80,7 +80,7 @@
<link rel="next" title="Synoptic Analysis" href="notebooks/synoptic/index.html" />
<meta name="viewport" content="width=device-width, initial-scale=1"/>
<meta name="docsearch:language" content="en"/>
<meta name="docbuild:last-update" content="14 June 2024"/>
<meta name="docbuild:last-update" content="17 June 2024"/>
</head>


Expand Down Expand Up @@ -811,7 +811,7 @@ <h3>Running on Your Own Machine<a class="headerlink" href="#running-on-your-own-

<div class="footer-item">
<p class="last-updated">
Last updated on 14 June 2024.
Last updated on 17 June 2024.
<br/>
</p>
</div>
Expand Down Expand Up @@ -865,7 +865,7 @@ <h3>Running on Your Own Machine<a class="headerlink" href="#running-on-your-own-

By MetPy Maintainers.

Last updated on 14 June 2024.
Last updated on 17 June 2024.
</p>
</div>
</div>
Expand Down
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
118 changes: 2 additions & 116 deletions _sources/notebooks/synoptic/Upperair_Obs.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,7 @@
"import numpy as np\n",
"import xarray as xr\n",
"\n",
"from metpy.io import add_station_lat_lon\n",
"from metpy.plots import StationPlot\n",
"from metpy.units import units\n",
"from siphon.simplewebservice.iastate import IAStateUpperAir"
Expand Down Expand Up @@ -123,119 +124,6 @@
" marker='x', color='black', transform=transform)"
]
},
{
"cell_type": "markdown",
"metadata": {
"cell_marker": "######################################################################"
},
"source": [
"Station Information\n",
"-------------------\n",
"\n",
"A helper function for obtaining radiosonde station information (e.g.,\n",
"latitude/longitude) requried to plot data obtained from each station.\n",
"Original code by github user sgdecker."
]
},
{
"cell_type": "code",
"execution_count": null,
"metadata": {
"lines_to_next_cell": 1
},
"outputs": [],
"source": [
"def station_info(stid):\n",
" r\"\"\"Provide information about weather stations.\n",
"\n",
" Parameters\n",
" ----------\n",
" stid: str or iterable object containing strs\n",
" The ICAO or IATA code(s) for which station information is requested.\n",
" with_units: bool\n",
" Whether to include units for values that have them. Default True.\n",
"\n",
" Returns\n",
" -------\n",
" info: dict\n",
" Information about the station(s) within a dictionary with these keys:\n",
" 'state': Two-character ID of the state/province where the station is located,\n",
" if applicable\n",
" 'name': The name of the station\n",
" 'lat': The latitude of the station [deg]\n",
" 'lon': The longitude of the station [deg]\n",
" 'elevation': The elevation of the station [m]\n",
" 'country': Two-character ID of the country where the station is located\n",
"\n",
" Modified code from Steven Decker, Rutgers University\n",
"\n",
" \"\"\"\n",
" # Provide a helper function for later usage\n",
" def str2latlon(s):\n",
" deg = float(s[:3])\n",
" mn = float(s[-3:-1])\n",
" if s[-1] == 'S' or s[-1] == 'W':\n",
" deg = -deg\n",
" mn = -mn\n",
" return deg + mn / 60.\n",
"\n",
" # Various constants describing the underlying data\n",
" url = 'https://www.aviationweather.gov/docs/metar/stations.txt'\n",
" # file = 'stations.txt'\n",
" state_bnds = slice(0, 2)\n",
" name_bnds = slice(3, 19)\n",
" icao_bnds = slice(20, 24)\n",
" iata_bnds = slice(26, 29)\n",
" lat_bnds = slice(39, 45)\n",
" lon_bnds = slice(47, 54)\n",
" z_bnds = slice(55, 59)\n",
" cntry_bnds = slice(81, 83)\n",
"\n",
" # Generalize to any number of IDs\n",
" if isinstance(stid, str):\n",
" stid = [stid]\n",
"\n",
" # Get the station dataset\n",
" infile = urllib.request.urlopen(url)\n",
" data = infile.readlines()\n",
"\n",
" state = []\n",
" name = []\n",
" lat = []\n",
" lon = []\n",
" z = []\n",
" cntry = []\n",
"\n",
" for s in stid:\n",
" s = s.upper()\n",
" for line_bytes in data:\n",
" line = line_bytes.decode('UTF-8')\n",
" icao = line[icao_bnds]\n",
" iata = line[iata_bnds]\n",
" if len(s) == 3 and s in iata or len(s) == 4 and s in icao:\n",
" state.append(line[state_bnds].strip())\n",
" name.append(line[name_bnds].strip())\n",
" lat.append(str2latlon(line[lat_bnds]))\n",
" lon.append(str2latlon(line[lon_bnds]))\n",
" z.append(float(line[z_bnds]))\n",
" cntry.append(line[cntry_bnds])\n",
"\n",
" break\n",
" else:\n",
" state.append('NA')\n",
" name.append('NA')\n",
" lat.append(np.nan)\n",
" lon.append(np.nan)\n",
" z.append(np.nan)\n",
" cntry.append('NA')\n",
"\n",
" infile.close()\n",
"\n",
" return {'state': np.array(state), 'name': np.array(name), 'lat': np.array(lat),\n",
" 'lon': np.array(lon), 'elevation': np.array(z), 'country': np.array(cntry),\n",
" 'units': {'lat': 'deg', 'lon': 'deg', 'z': 'm'}}"
]
},
{
"cell_type": "markdown",
"metadata": {
Expand Down Expand Up @@ -312,9 +200,7 @@
"df = data[data_subset]\n",
"\n",
"# Get station lat/lon from look-up file; add to Dataframe\n",
"stn_info = station_info(list(df.station.values))\n",
"df.insert(10, 'latitude', stn_info['lat'])\n",
"df.insert(11, 'longitude', stn_info['lon'])"
"df = add_station_lat_lon(df)"
]
},
{
Expand Down
6 changes: 3 additions & 3 deletions genindex.html
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,7 @@
<link rel="search" title="Search" href="search.html" />
<meta name="viewport" content="width=device-width, initial-scale=1"/>
<meta name="docsearch:language" content="en"/>
<meta name="docbuild:last-update" content="14 June 2024"/>
<meta name="docbuild:last-update" content="17 June 2024"/>
</head>


Expand Down Expand Up @@ -600,7 +600,7 @@ <h1 id="index">Index</h1>

<div class="footer-item">
<p class="last-updated">
Last updated on 14 June 2024.
Last updated on 17 June 2024.
<br/>
</p>
</div>
Expand Down Expand Up @@ -654,7 +654,7 @@ <h1 id="index">Index</h1>

By MetPy Maintainers.

Last updated on 14 June 2024.
Last updated on 17 June 2024.
</p>
</div>
</div>
Expand Down
36 changes: 18 additions & 18 deletions notebooks/convective/MUCAPE.html

Large diffs are not rendered by default.

34 changes: 17 additions & 17 deletions notebooks/convective/TCPW.html

Large diffs are not rendered by default.

6 changes: 3 additions & 3 deletions notebooks/convective/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,7 @@
<link rel="prev" title="Sounding Plotter" href="../skewt/Sounding_Plotter.html" />
<meta name="viewport" content="width=device-width, initial-scale=1"/>
<meta name="docsearch:language" content="en"/>
<meta name="docbuild:last-update" content="14 June 2024"/>
<meta name="docbuild:last-update" content="17 June 2024"/>
</head>


Expand Down Expand Up @@ -703,7 +703,7 @@ <h1>Convective Calculations<a class="headerlink" href="#convective-calculations"

<div class="footer-item">
<p class="last-updated">
Last updated on 14 June 2024.
Last updated on 17 June 2024.
<br/>
</p>
</div>
Expand Down Expand Up @@ -757,7 +757,7 @@ <h1>Convective Calculations<a class="headerlink" href="#convective-calculations"

By MetPy Maintainers.

Last updated on 14 June 2024.
Last updated on 17 June 2024.
</p>
</div>
</div>
Expand Down
10 changes: 5 additions & 5 deletions notebooks/convective/miller_composite.html
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,7 @@
<link rel="prev" title="Total Column Precipitable Water (TCPW)" href="TCPW.html" />
<meta name="viewport" content="width=device-width, initial-scale=1"/>
<meta name="docsearch:language" content="en"/>
<meta name="docbuild:last-update" content="14 June 2024"/>
<meta name="docbuild:last-update" content="17 June 2024"/>
</head>


Expand Down Expand Up @@ -591,9 +591,9 @@ <h1>Miller Composite Chart<a class="headerlink" href="#miller-composite-chart" t
</div>
</div>
<div class="cell_output docutils container">
<div class="output stderr highlight-myst-ansi notranslate"><div class="highlight"><pre><span></span>/tmp/ipykernel_2455/1703524492.py:2: UserWarning: Vertical dimension number not found. Defaulting to (..., Z, Y, X) order.
<div class="output stderr highlight-myst-ansi notranslate"><div class="highlight"><pre><span></span>/tmp/ipykernel_2444/1703524492.py:2: UserWarning: Vertical dimension number not found. Defaulting to (..., Z, Y, X) order.
vort_adv_500 = mpcalc.advection(avor_500, u_500, v_500,) * 1e9
/tmp/ipykernel_2455/1703524492.py:2: UserWarning: Latitude and longitude computed on-demand, which may be an expensive operation. To avoid repeating this computation, assign these coordinates ahead of time with .metpy.assign_latitude_longitude().
/tmp/ipykernel_2444/1703524492.py:2: UserWarning: Latitude and longitude computed on-demand, which may be an expensive operation. To avoid repeating this computation, assign these coordinates ahead of time with .metpy.assign_latitude_longitude().
vort_adv_500 = mpcalc.advection(avor_500, u_500, v_500,) * 1e9
</pre></div>
</div>
Expand Down Expand Up @@ -1047,7 +1047,7 @@ <h1>Miller Composite Chart<a class="headerlink" href="#miller-composite-chart" t

<div class="footer-item">
<p class="last-updated">
Last updated on 14 June 2024.
Last updated on 17 June 2024.
<br/>
</p>
</div>
Expand Down Expand Up @@ -1101,7 +1101,7 @@ <h1>Miller Composite Chart<a class="headerlink" href="#miller-composite-chart" t

By MetPy Maintainers.

Last updated on 14 June 2024.
Last updated on 17 June 2024.
</p>
</div>
</div>
Expand Down
6 changes: 3 additions & 3 deletions notebooks/declarative/Declarative_300hPa.html
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,7 @@
<link rel="prev" title="MetPy’s Simplified Plotting Interface" href="index.html" />
<meta name="viewport" content="width=device-width, initial-scale=1"/>
<meta name="docsearch:language" content="en"/>
<meta name="docbuild:last-update" content="14 June 2024"/>
<meta name="docbuild:last-update" content="17 June 2024"/>
</head>


Expand Down Expand Up @@ -885,7 +885,7 @@ <h2>Declarative Plot<a class="headerlink" href="#declarative-plot" title="Link t

<div class="footer-item">
<p class="last-updated">
Last updated on 14 June 2024.
Last updated on 17 June 2024.
<br/>
</p>
</div>
Expand Down Expand Up @@ -939,7 +939,7 @@ <h2>Declarative Plot<a class="headerlink" href="#declarative-plot" title="Link t

By MetPy Maintainers.

Last updated on 14 June 2024.
Last updated on 17 June 2024.
</p>
</div>
</div>
Expand Down
6 changes: 3 additions & 3 deletions notebooks/declarative/declarative_500_hPa.html
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,7 @@
<link rel="prev" title="MetPy Declarative - 300 hPa" href="Declarative_300hPa.html" />
<meta name="viewport" content="width=device-width, initial-scale=1"/>
<meta name="docsearch:language" content="en"/>
<meta name="docbuild:last-update" content="14 June 2024"/>
<meta name="docbuild:last-update" content="17 June 2024"/>
</head>


Expand Down Expand Up @@ -842,7 +842,7 @@ <h2>The Plot<a class="headerlink" href="#the-plot" title="Link to this heading">

<div class="footer-item">
<p class="last-updated">
Last updated on 14 June 2024.
Last updated on 17 June 2024.
<br/>
</p>
</div>
Expand Down Expand Up @@ -896,7 +896,7 @@ <h2>The Plot<a class="headerlink" href="#the-plot" title="Link to this heading">

By MetPy Maintainers.

Last updated on 14 June 2024.
Last updated on 17 June 2024.
</p>
</div>
</div>
Expand Down
6 changes: 3 additions & 3 deletions notebooks/declarative/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,7 @@
<link rel="prev" title="Smoothing Contours" href="../specialty/Smoothing_Contours.html" />
<meta name="viewport" content="width=device-width, initial-scale=1"/>
<meta name="docsearch:language" content="en"/>
<meta name="docbuild:last-update" content="14 June 2024"/>
<meta name="docbuild:last-update" content="17 June 2024"/>
</head>


Expand Down Expand Up @@ -703,7 +703,7 @@ <h1>MetPy’s Simplified Plotting Interface<a class="headerlink" href="#metpys-s

<div class="footer-item">
<p class="last-updated">
Last updated on 14 June 2024.
Last updated on 17 June 2024.
<br/>
</p>
</div>
Expand Down Expand Up @@ -757,7 +757,7 @@ <h1>MetPy’s Simplified Plotting Interface<a class="headerlink" href="#metpys-s

By MetPy Maintainers.

Last updated on 14 June 2024.
Last updated on 17 June 2024.
</p>
</div>
</div>
Expand Down
6 changes: 3 additions & 3 deletions notebooks/skewt/Advanced_Sounding.html
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,7 @@
<link rel="prev" title="Skew-T Analysis" href="index.html" />
<meta name="viewport" content="width=device-width, initial-scale=1"/>
<meta name="docsearch:language" content="en"/>
<meta name="docbuild:last-update" content="14 June 2024"/>
<meta name="docbuild:last-update" content="17 June 2024"/>
</head>


Expand Down Expand Up @@ -879,7 +879,7 @@ <h2>Create Sounding Plot<a class="headerlink" href="#create-sounding-plot" title

<div class="footer-item">
<p class="last-updated">
Last updated on 14 June 2024.
Last updated on 17 June 2024.
<br/>
</p>
</div>
Expand Down Expand Up @@ -933,7 +933,7 @@ <h2>Create Sounding Plot<a class="headerlink" href="#create-sounding-plot" title

By MetPy Maintainers.

Last updated on 14 June 2024.
Last updated on 17 June 2024.
</p>
</div>
</div>
Expand Down
6 changes: 3 additions & 3 deletions notebooks/skewt/Foundational_Sounding.html
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,7 @@
<link rel="prev" title="Advanced Sounding" href="Advanced_Sounding.html" />
<meta name="viewport" content="width=device-width, initial-scale=1"/>
<meta name="docsearch:language" content="en"/>
<meta name="docbuild:last-update" content="14 June 2024"/>
<meta name="docbuild:last-update" content="17 June 2024"/>
</head>


Expand Down Expand Up @@ -1182,7 +1182,7 @@ <h2>Resources and references<a class="headerlink" href="#resources-and-reference

<div class="footer-item">
<p class="last-updated">
Last updated on 14 June 2024.
Last updated on 17 June 2024.
<br/>
</p>
</div>
Expand Down Expand Up @@ -1236,7 +1236,7 @@ <h2>Resources and references<a class="headerlink" href="#resources-and-reference

By MetPy Maintainers.

Last updated on 14 June 2024.
Last updated on 17 June 2024.
</p>
</div>
</div>
Expand Down
Loading

0 comments on commit b503240

Please sign in to comment.