From 6976fec45e4796e692220f5e7cab17fbea643478 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=C3=89ric=20Dupuis?= Date: Thu, 6 Jun 2024 13:06:29 -0400 Subject: [PATCH] fix missing dataset --- docs/notebooks/figanos_multiplots.ipynb | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/docs/notebooks/figanos_multiplots.ipynb b/docs/notebooks/figanos_multiplots.ipynb index fc16da3..b0ded4e 100644 --- a/docs/notebooks/figanos_multiplots.ipynb +++ b/docs/notebooks/figanos_multiplots.ipynb @@ -219,18 +219,22 @@ "from xclim.core.units import convert_units_to\n", "\n", "ds = open_dataset(\"sdba/CanESM2_1950-2100.nc\").sel(time=slice(\"1950\", \"2013\"))\n", - "ds2 = open_dataset(\"sdba/ahccd_1950-2013.nc\")\n", + "ds1 = open_dataset(\"sdba/ahccd_1950-2013.nc\")\n", + "ds2 = open_dataset(\"sdba/nrcan_1950-2013.nc\")\n", "for v in ds.data_vars: \n", + " ds1[v] = convert_units_to(ds1[v], ds[v], context=\"hydro\")\n", " ds2[v] = convert_units_to(ds2[v], ds[v], context=\"hydro\")\n", "tx_ref = ds.tasmax.isel(location=0)\n", - "tx_sim = ds2.tasmax.isel(location=0)\n", + "tx_sim = ds1.tasmax.isel(location=0)\n", + "tx_sim2 = ds2.tasmax.isel(location=0)\n", "out = {}\n", "out[\"sim\"] = sdba.measures.taylordiagram(ref=tx_ref, sim=tx_sim, dim=\"time\")\n", "out[\"sim2\"] = sdba.measures.taylordiagram(ref=tx_ref, sim=tx_sim2, dim=\"time\")\n", "# In the default behaviour of `fg.taylordiagram`, the keys of the dictionary of \n", "# DataArray are used for the legend\n", "# A single DataArray can also be passed.\n", - "fg.taylordiagram(out)\n" + "fg.taylordiagram(out)\n", + "\n" ] }, {