diff --git a/docs/using/matching.rst b/docs/using/matching.rst index f0259226..92d810b2 100644 --- a/docs/using/matching.rst +++ b/docs/using/matching.rst @@ -10,7 +10,12 @@ the attributes of the input datasets must match, such as the list of variables for `concat` or the `dates` and `frequency` for `join`. You can let the package automatically adjust the attributes of the input -datasets using the `adjust` keyword: +datasets using the `adjust` keyword, to adjust one of the attributes: + +.. literalinclude:: matching1_.py + :language: python + +or more than one attribute: .. literalinclude:: matching1_.py :language: python diff --git a/docs/using/matching0_.py b/docs/using/matching0_.py new file mode 100644 index 00000000..85576d5f --- /dev/null +++ b/docs/using/matching0_.py @@ -0,0 +1,4 @@ +ds = open_dataset( + join=[dataset1, dataset2], + adjust="frequency", +) diff --git a/docs/using/matching2_.py b/docs/using/matching2_.py index 52197ddf..8deaa835 100644 --- a/docs/using/matching2_.py +++ b/docs/using/matching2_.py @@ -1 +1 @@ -ds = open_dataset(join=[dataset1, dataset2], adjust=["dates"]) +ds = open_dataset(join=[dataset1, dataset2], adjust="dates")