.. DO NOT EDIT. .. THIS FILE WAS AUTOMATICALLY GENERATED BY SPHINX-GALLERY. .. TO MAKE CHANGES, EDIT THE SOURCE PYTHON FILE: .. "source/auto_examples/plotting/plot_qc.py" .. LINE NUMBERS ARE GIVEN BELOW. .. only:: html .. note:: :class: sphx-glr-download-link-note :ref:`Go to the end ` to download the full example code. .. rst-class:: sphx-glr-example-title .. _sphx_glr_source_auto_examples_plotting_plot_qc.py: Plotting QC Flags ----------------- Simple example for cleaning up a dataset and plotting the data and its QC flags Author: Adam Theisen .. GENERATED FROM PYTHON SOURCE LINES 10-36 .. image-sg:: /source/auto_examples/plotting/images/sphx_glr_plot_qc_001.png :alt: sgpmetE13.b1 temp_mean on 20190101 :srcset: /source/auto_examples/plotting/images/sphx_glr_plot_qc_001.png :class: sphx-glr-single-img .. code-block:: Python from arm_test_data import DATASETS from matplotlib import pyplot as plt import act # Read in sample MET data filename_met = DATASETS.fetch('sgpmetE13.b1.20190101.000000.cdf') ds = act.io.arm.read_arm_netcdf(filename_met) # In order to utilize all the ACT QC modules and plot the QC, # we need to clean up the dataset to follow CF standards ds.clean.cleanup() # Plot data # Creat Plot Display variable = 'temp_mean' display = act.plotting.TimeSeriesDisplay(ds, figsize=(15, 10), subplot_shape=(2,)) # Plot temperature data in top plot display.plot(variable, subplot_index=(0,)) # Plot QC data display.qc_flag_block_plot(variable, subplot_index=(1,)) plt.show() .. rst-class:: sphx-glr-timing **Total running time of the script:** (0 minutes 0.553 seconds) .. _sphx_glr_download_source_auto_examples_plotting_plot_qc.py: .. only:: html .. container:: sphx-glr-footer sphx-glr-footer-example .. container:: sphx-glr-download sphx-glr-download-jupyter :download:`Download Jupyter notebook: plot_qc.ipynb ` .. container:: sphx-glr-download sphx-glr-download-python :download:`Download Python source code: plot_qc.py ` .. container:: sphx-glr-download sphx-glr-download-zip :download:`Download zipped: plot_qc.zip ` .. only:: html .. rst-class:: sphx-glr-signature `Gallery generated by Sphinx-Gallery `_