{ "cells": [ { "cell_type": "markdown", "metadata": {}, "source": [ "\n# Create a plot of NEXRAD reflectivity\n\nAn example which creates a plot containing the first collected scan from a\nNEXRAD file.\n" ] }, { "cell_type": "code", "execution_count": null, "metadata": { "collapsed": false }, "outputs": [], "source": [ "print(__doc__)\n\n# Author: Jonathan J. Helmus (jhelmus@anl.gov)\n# License: BSD 3 clause\n\nimport matplotlib.pyplot as plt\n\nimport pyart\nfrom pyart.testing import get_test_data\n\n# open the file, create the displays and figure\nfilename = get_test_data(\"Level2_KATX_20130717_1950.ar2v\")\nradar = pyart.io.read_nexrad_archive(filename)\ndisplay = pyart.graph.RadarDisplay(radar)\nfig = plt.figure(figsize=(6, 5))\n\n# plot super resolution reflectivity\nax = fig.add_subplot(111)\ndisplay.plot(\n \"reflectivity\",\n 0,\n title=\"NEXRAD Reflectivity\",\n vmin=-32,\n vmax=64,\n colorbar_label=\"\",\n ax=ax,\n)\ndisplay.plot_range_ring(radar.range[\"data\"][-1] / 1000.0, ax=ax)\ndisplay.set_limits(xlim=(-500, 500), ylim=(-500, 500), ax=ax)\nplt.show()" ] } ], "metadata": { "kernelspec": { "display_name": "Python 3", "language": "python", "name": "python3" }, "language_info": { "codemirror_mode": { "name": "ipython", "version": 3 }, "file_extension": ".py", "mimetype": "text/x-python", "name": "python", "nbconvert_exporter": "python", "pygments_lexer": "ipython3", "version": "3.14.3" } }, "nbformat": 4, "nbformat_minor": 0 }