.. DO NOT EDIT. .. THIS FILE WAS AUTOMATICALLY GENERATED BY SPHINX-GALLERY. .. TO MAKE CHANGES, EDIT THE SOURCE PYTHON FILE: .. "gallery/example_long_global_thredds.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_gallery_example_long_global_thredds.py: Thredds (global) ================================== .. GENERATED FROM PYTHON SOURCE LINES 6-26 .. code-block:: Python from datetime import datetime, timedelta from opendrift.models.oceandrift import OceanDrift # Basic ocean drift module: current + 2% of wind o = OceanDrift() # Adding readers for global Thredds datasets: # - Ocean forecast from global HYCOM model # - Weather forecast from NOAA/NCEP o.add_readers_from_list([ 'https://tds.hycom.org/thredds/dodsC/GLBy0.08/latest', 'https://pae-paha.pacioos.hawaii.edu/thredds/dodsC/ncep_global/NCEP_Global_Atmospheric_Model_best.ncd']) o.seed_elements(lat=24, lon=-81, time=datetime.utcnow(), number=5000, radius=10000) o.run(time_step=timedelta(minutes=30), duration=timedelta(days=5)) o.animation() .. _sphx_glr_download_gallery_example_long_global_thredds.py: .. only:: html .. container:: sphx-glr-footer sphx-glr-footer-example .. container:: sphx-glr-download sphx-glr-download-jupyter :download:`Download Jupyter notebook: example_long_global_thredds.ipynb ` .. container:: sphx-glr-download sphx-glr-download-python :download:`Download Python source code: example_long_global_thredds.py ` .. only:: html .. rst-class:: sphx-glr-signature `Gallery generated by Sphinx-Gallery `_