You can run this notebook in Binder, in Colab, in Deepnote or in Kaggle.

[1]:
!pip3 install --quiet climetlab
[2]:
!test -f test.grib || wget https://github.com/ecmwf/climetlab/raw/main/docs/examples/test.grib
[3]:
!test -f test.nc || wget https://github.com/ecmwf/climetlab/raw/main/docs/examples/test.nc

Reading data from a file

[4]:
import climetlab as cml

Plot GRIB data

[5]:
source = cml.load_source("file", "test.grib")
for s in source:
    cml.plot_map(s)
../_images/examples_01-source-file_7_0.png
../_images/examples_01-source-file_7_1.png

Plot NetCDF data

[6]:
source = cml.load_source("file", "test.nc")
for s in source:
    cml.plot_map(s)
../_images/examples_01-source-file_9_0.png
../_images/examples_01-source-file_9_1.png