.. DO NOT EDIT. .. THIS FILE WAS AUTOMATICALLY GENERATED BY SPHINX-GALLERY. .. TO MAKE CHANGES, EDIT THE SOURCE PYTHON FILE: .. "sample_data/texas-wind.py" .. LINE NUMBERS ARE GIVEN BELOW. .. only:: html .. note:: :class: sphx-glr-download-link-note Click :ref:`here ` to download the full example code .. rst-class:: sphx-glr-example-title .. _sphx_glr_sample_data_texas-wind.py: [DEPRECATED] Wind speed data from Texas ======================================= .. warning:: All sample datasets in Verde are deprecated and will be **removed in Verde v2.0.0**. The tutorials/examples will transition to using `Ensaio `__ instead. This is average wind speed and air temperature for data for the state of Texas, USA, on February 26 2018. The original data was downloaded from `Iowa State University `__. .. GENERATED FROM PYTHON SOURCE LINES 22-57 .. image-sg:: /sample_data/images/sphx_glr_texas-wind_001.png :alt: Wind speed and air temperature for Texas :srcset: /sample_data/images/sphx_glr_texas-wind_001.png :class: sphx-glr-single-img .. rst-class:: sphx-glr-script-out Out: .. code-block:: none station_id longitude ... wind_speed_east_knots wind_speed_north_knots 0 0F2 -97.7756 ... 1.032920 -2.357185 1 11R -96.3742 ... 1.692155 2.982564 2 2F5 -101.9018 ... -1.110056 -0.311412 3 3T5 -96.9500 ... 1.695097 3.018448 4 5C1 -98.6946 ... 1.271400 1.090743 [5 rows x 6 columns] | .. code-block:: default import cartopy.crs as ccrs import matplotlib.pyplot as plt import verde as vd # The data are in a pandas.DataFrame data = vd.datasets.fetch_texas_wind() print(data.head()) # Make a Mercator map of the data using Cartopy plt.figure(figsize=(8, 6)) ax = plt.axes(projection=ccrs.Mercator()) ax.set_title("Wind speed and air temperature for Texas") # Plot the air temperature as colored circles and the wind speed as vectors. plt.scatter( data.longitude, data.latitude, c=data.air_temperature_c, s=100, cmap="plasma", transform=ccrs.PlateCarree(), ) plt.colorbar().set_label("Air temperature (C)") ax.quiver( data.longitude.values, data.latitude.values, data.wind_speed_east_knots.values, data.wind_speed_north_knots.values, width=0.003, transform=ccrs.PlateCarree(), ) # Use an utility function to add tick labels and land and ocean features to the # map. vd.datasets.setup_texas_wind_map(ax) plt.show() .. rst-class:: sphx-glr-timing **Total running time of the script:** ( 0 minutes 0.194 seconds) .. _sphx_glr_download_sample_data_texas-wind.py: .. only :: html .. container:: sphx-glr-footer :class: sphx-glr-footer-example .. container:: sphx-glr-download sphx-glr-download-python :download:`Download Python source code: texas-wind.py ` .. container:: sphx-glr-download sphx-glr-download-jupyter :download:`Download Jupyter notebook: texas-wind.ipynb ` .. only:: html .. rst-class:: sphx-glr-signature `Gallery generated by Sphinx-Gallery `_