{"diffoscope-json-version": 1, "source1": "/srv/reproducible-results/rbuild-debian/r-b-build.58uyUoLJ/b1/python-xarray_0.16.2-2_arm64.changes", "source2": "/srv/reproducible-results/rbuild-debian/r-b-build.58uyUoLJ/b2/python-xarray_0.16.2-2_arm64.changes", "unified_diff": null, "details": [{"source1": "Files", "source2": "Files", "unified_diff": "@@ -1,3 +1,3 @@\n \n- 6fd40bc6a01c506561aef3434ce9c75f 2044668 doc optional python-xarray-doc_0.16.2-2_all.deb\n+ 818430b1efff05836954b02a711b4379 2044792 doc optional python-xarray-doc_0.16.2-2_all.deb\n 9a2456450e2c51d89ccb00d8c4a100d8 486600 python optional python3-xarray_0.16.2-2_all.deb\n"}, {"source1": "python-xarray-doc_0.16.2-2_all.deb", "source2": "python-xarray-doc_0.16.2-2_all.deb", "unified_diff": null, "details": [{"source1": "file list", "source2": "file list", "unified_diff": "@@ -1,3 +1,3 @@\n -rw-r--r-- 0 0 0 4 2021-01-02 13:06:33.000000 debian-binary\n--rw-r--r-- 0 0 0 4984 2021-01-02 13:06:33.000000 control.tar.xz\n--rw-r--r-- 0 0 0 2039492 2021-01-02 13:06:33.000000 data.tar.xz\n+-rw-r--r-- 0 0 0 4980 2021-01-02 13:06:33.000000 control.tar.xz\n+-rw-r--r-- 0 0 0 2039620 2021-01-02 13:06:33.000000 data.tar.xz\n"}, {"source1": "control.tar.xz", "source2": "control.tar.xz", "unified_diff": null, "details": [{"source1": "control.tar", "source2": "control.tar", "unified_diff": null, "details": [{"source1": "./md5sums", "source2": "./md5sums", "unified_diff": null, "details": [{"source1": "./md5sums", "source2": "./md5sums", "comments": ["Files differ"], "unified_diff": null}]}]}]}, {"source1": "data.tar.xz", "source2": "data.tar.xz", "unified_diff": null, "details": [{"source1": "data.tar", "source2": "data.tar", "unified_diff": null, "details": [{"source1": "file list", "source2": "file list", "unified_diff": "@@ -182,50 +182,50 @@\n -rw-r--r-- 0 root (0) root (0) 57284 2021-01-02 13:06:33.000000 ./usr/share/doc/python-xarray-doc/html/combining.html\n -rw-r--r-- 0 root (0) root (0) 110193 2021-01-02 13:06:33.000000 ./usr/share/doc/python-xarray-doc/html/computation.html\n -rw-r--r-- 0 root (0) root (0) 90070 2021-01-02 13:06:33.000000 ./usr/share/doc/python-xarray-doc/html/contributing.html\n -rw-r--r-- 0 root (0) root (0) 79117 2021-01-02 13:06:33.000000 ./usr/share/doc/python-xarray-doc/html/dask.html\n -rw-r--r-- 0 root (0) root (0) 102950 2021-01-02 13:06:33.000000 ./usr/share/doc/python-xarray-doc/html/data-structures.html\n -rw-r--r-- 0 root (0) root (0) 17225 2021-01-02 13:06:33.000000 ./usr/share/doc/python-xarray-doc/html/duckarrays.html\n drwxr-xr-x 0 root (0) root (0) 0 2021-01-02 13:06:33.000000 ./usr/share/doc/python-xarray-doc/html/examples/\n--rw-r--r-- 0 root (0) root (0) 68084 2021-01-02 13:06:33.000000 ./usr/share/doc/python-xarray-doc/html/examples/ERA5-GRIB-example.html\n+-rw-r--r-- 0 root (0) root (0) 68085 2021-01-02 13:06:33.000000 ./usr/share/doc/python-xarray-doc/html/examples/ERA5-GRIB-example.html\n -rw-r--r-- 0 root (0) root (0) 5090 2021-01-02 13:06:33.000000 ./usr/share/doc/python-xarray-doc/html/examples/ERA5-GRIB-example.ipynb.gz\n--rw-r--r-- 0 root (0) root (0) 49514 2021-01-02 13:06:33.000000 ./usr/share/doc/python-xarray-doc/html/examples/ROMS_ocean_model.html\n+-rw-r--r-- 0 root (0) root (0) 49515 2021-01-02 13:06:33.000000 ./usr/share/doc/python-xarray-doc/html/examples/ROMS_ocean_model.html\n -rw-r--r-- 0 root (0) root (0) 18700 2021-01-02 13:06:33.000000 ./usr/share/doc/python-xarray-doc/html/examples/ROMS_ocean_model.ipynb.gz\n--rw-r--r-- 0 root (0) root (0) 107469 2021-01-02 13:06:33.000000 ./usr/share/doc/python-xarray-doc/html/examples/apply_ufunc_vectorize_1d.html\n+-rw-r--r-- 0 root (0) root (0) 107470 2021-01-02 13:06:33.000000 ./usr/share/doc/python-xarray-doc/html/examples/apply_ufunc_vectorize_1d.html\n -rw-r--r-- 0 root (0) root (0) 8091 2021-01-02 13:06:33.000000 ./usr/share/doc/python-xarray-doc/html/examples/apply_ufunc_vectorize_1d.ipynb.gz\n--rw-r--r-- 0 root (0) root (0) 38212 2021-01-02 13:06:33.000000 ./usr/share/doc/python-xarray-doc/html/examples/area_weighted_temperature.html\n--rw-r--r-- 0 root (0) root (0) 14552 2021-01-02 13:06:33.000000 ./usr/share/doc/python-xarray-doc/html/examples/area_weighted_temperature.ipynb.gz\n--rw-r--r-- 0 root (0) root (0) 47846 2021-01-02 13:06:33.000000 ./usr/share/doc/python-xarray-doc/html/examples/monthly-means.html\n--rw-r--r-- 0 root (0) root (0) 3166 2021-01-02 13:06:33.000000 ./usr/share/doc/python-xarray-doc/html/examples/monthly-means.ipynb.gz\n--rw-r--r-- 0 root (0) root (0) 41913 2021-01-02 13:06:33.000000 ./usr/share/doc/python-xarray-doc/html/examples/multidimensional-coords.html\n--rw-r--r-- 0 root (0) root (0) 7648 2021-01-02 13:06:33.000000 ./usr/share/doc/python-xarray-doc/html/examples/multidimensional-coords.ipynb.gz\n--rw-r--r-- 0 root (0) root (0) 81220 2021-01-02 13:06:33.000000 ./usr/share/doc/python-xarray-doc/html/examples/visualization_gallery.html\n--rw-r--r-- 0 root (0) root (0) 5306 2021-01-02 13:06:33.000000 ./usr/share/doc/python-xarray-doc/html/examples/visualization_gallery.ipynb.gz\n+-rw-r--r-- 0 root (0) root (0) 38213 2021-01-02 13:06:33.000000 ./usr/share/doc/python-xarray-doc/html/examples/area_weighted_temperature.html\n+-rw-r--r-- 0 root (0) root (0) 14555 2021-01-02 13:06:33.000000 ./usr/share/doc/python-xarray-doc/html/examples/area_weighted_temperature.ipynb.gz\n+-rw-r--r-- 0 root (0) root (0) 47847 2021-01-02 13:06:33.000000 ./usr/share/doc/python-xarray-doc/html/examples/monthly-means.html\n+-rw-r--r-- 0 root (0) root (0) 3168 2021-01-02 13:06:33.000000 ./usr/share/doc/python-xarray-doc/html/examples/monthly-means.ipynb.gz\n+-rw-r--r-- 0 root (0) root (0) 41914 2021-01-02 13:06:33.000000 ./usr/share/doc/python-xarray-doc/html/examples/multidimensional-coords.html\n+-rw-r--r-- 0 root (0) root (0) 7649 2021-01-02 13:06:33.000000 ./usr/share/doc/python-xarray-doc/html/examples/multidimensional-coords.ipynb.gz\n+-rw-r--r-- 0 root (0) root (0) 81221 2021-01-02 13:06:33.000000 ./usr/share/doc/python-xarray-doc/html/examples/visualization_gallery.html\n+-rw-r--r-- 0 root (0) root (0) 5305 2021-01-02 13:06:33.000000 ./usr/share/doc/python-xarray-doc/html/examples/visualization_gallery.ipynb.gz\n -rw-r--r-- 0 root (0) root (0) 90739 2021-01-02 13:06:33.000000 ./usr/share/doc/python-xarray-doc/html/examples/weather-data.html\n--rw-r--r-- 0 root (0) root (0) 208634 2021-01-02 13:06:33.000000 ./usr/share/doc/python-xarray-doc/html/examples/weather-data.ipynb.gz\n+-rw-r--r-- 0 root (0) root (0) 208631 2021-01-02 13:06:33.000000 ./usr/share/doc/python-xarray-doc/html/examples/weather-data.ipynb.gz\n -rw-r--r-- 0 root (0) root (0) 12844 2021-01-02 13:06:33.000000 ./usr/share/doc/python-xarray-doc/html/examples.html\n -rw-r--r-- 0 root (0) root (0) 33153 2021-01-02 13:06:33.000000 ./usr/share/doc/python-xarray-doc/html/faq.html\n -rw-r--r-- 0 root (0) root (0) 9794 2021-01-02 13:06:33.000000 ./usr/share/doc/python-xarray-doc/html/genindex.html\n -rw-r--r-- 0 root (0) root (0) 38989 2021-01-02 13:06:33.000000 ./usr/share/doc/python-xarray-doc/html/groupby.html\n -rw-r--r-- 0 root (0) root (0) 19098 2021-01-02 13:06:33.000000 ./usr/share/doc/python-xarray-doc/html/howdoi.html\n -rw-r--r-- 0 root (0) root (0) 17531 2021-01-02 13:06:33.000000 ./usr/share/doc/python-xarray-doc/html/index.html\n--rw-r--r-- 0 root (0) root (0) 183015 2021-01-02 13:06:33.000000 ./usr/share/doc/python-xarray-doc/html/indexing.html\n+-rw-r--r-- 0 root (0) root (0) 183016 2021-01-02 13:06:33.000000 ./usr/share/doc/python-xarray-doc/html/indexing.html\n -rw-r--r-- 0 root (0) root (0) 24660 2021-01-02 13:06:33.000000 ./usr/share/doc/python-xarray-doc/html/installing.html\n--rw-r--r-- 0 root (0) root (0) 34152 2021-01-02 13:06:33.000000 ./usr/share/doc/python-xarray-doc/html/internals.html\n--rw-r--r-- 0 root (0) root (0) 89977 2021-01-02 13:06:33.000000 ./usr/share/doc/python-xarray-doc/html/interpolation.html\n+-rw-r--r-- 0 root (0) root (0) 34153 2021-01-02 13:06:33.000000 ./usr/share/doc/python-xarray-doc/html/internals.html\n+-rw-r--r-- 0 root (0) root (0) 89978 2021-01-02 13:06:33.000000 ./usr/share/doc/python-xarray-doc/html/interpolation.html\n -rw-r--r-- 0 root (0) root (0) 125247 2021-01-02 13:06:33.000000 ./usr/share/doc/python-xarray-doc/html/io.html\n -rw-r--r-- 0 root (0) root (0) 13348 2021-01-02 13:06:33.000000 ./usr/share/doc/python-xarray-doc/html/objects.inv\n -rw-r--r-- 0 root (0) root (0) 41507 2021-01-02 13:06:33.000000 ./usr/share/doc/python-xarray-doc/html/pandas.html\n--rw-r--r-- 0 root (0) root (0) 208687 2021-01-02 13:06:33.000000 ./usr/share/doc/python-xarray-doc/html/plotting.html\n+-rw-r--r-- 0 root (0) root (0) 208689 2021-01-02 13:06:33.000000 ./usr/share/doc/python-xarray-doc/html/plotting.html\n -rw-r--r-- 0 root (0) root (0) 46141 2021-01-02 13:06:33.000000 ./usr/share/doc/python-xarray-doc/html/quick-overview.html\n -rw-r--r-- 0 root (0) root (0) 21186 2021-01-02 13:06:33.000000 ./usr/share/doc/python-xarray-doc/html/related-projects.html\n -rw-r--r-- 0 root (0) root (0) 56597 2021-01-02 13:06:33.000000 ./usr/share/doc/python-xarray-doc/html/reshaping.html\n -rw-r--r-- 0 root (0) root (0) 22480 2021-01-02 13:06:33.000000 ./usr/share/doc/python-xarray-doc/html/roadmap.html\n -rw-r--r-- 0 root (0) root (0) 7920 2021-01-02 13:06:33.000000 ./usr/share/doc/python-xarray-doc/html/search.html\n--rw-r--r-- 0 root (0) root (0) 100584 2021-01-02 13:06:33.000000 ./usr/share/doc/python-xarray-doc/html/searchindex.js\n+-rw-r--r-- 0 root (0) root (0) 100592 2021-01-02 13:06:33.000000 ./usr/share/doc/python-xarray-doc/html/searchindex.js\n -rw-r--r-- 0 root (0) root (0) 20789 2021-01-02 13:06:33.000000 ./usr/share/doc/python-xarray-doc/html/terminology.html\n -rw-r--r-- 0 root (0) root (0) 39824 2021-01-02 13:06:33.000000 ./usr/share/doc/python-xarray-doc/html/time-series.html\n -rw-r--r-- 0 root (0) root (0) 41691 2021-01-02 13:06:33.000000 ./usr/share/doc/python-xarray-doc/html/weather-climate.html\n -rw-r--r-- 0 root (0) root (0) 574383 2021-01-02 13:06:33.000000 ./usr/share/doc/python-xarray-doc/html/whats-new.html\n -rw-r--r-- 0 root (0) root (0) 18651 2021-01-02 13:06:33.000000 ./usr/share/doc/python-xarray-doc/html/why-xarray.html\n drwxr-xr-x 0 root (0) root (0) 0 2021-01-02 13:06:33.000000 ./usr/share/doc-base/\n -rw-r--r-- 0 root (0) root (0) 290 2021-01-02 13:06:33.000000 ./usr/share/doc-base/python-xarray-doc\n"}, {"source1": "./usr/share/doc/python-xarray-doc/html/dask.html", "source2": "./usr/share/doc/python-xarray-doc/html/dask.html", "unified_diff": "@@ -300,15 +300,15 @@\n
You\u2019ll notice that printing a dataset still shows a preview of array values,\n even if they are actually Dask arrays. We can do this quickly with Dask because\n we only need to compute the first few values (typically from the first block).\n To reveal the true nature of an array, print a DataArray:
\nIn [3]: ds.temperature\n Out[3]: \n <xarray.DataArray 'temperature' (time: 30, latitude: 180, longitude: 180)>\n-dask.array<open_dataset-a94180edfd9e3550bf55a27876f45d80temperature, shape=(30, 180, 180), dtype=float64, chunksize=(10, 180, 180), chunktype=numpy.ndarray>\n+dask.array<open_dataset-277162681b3377c87ddac5999bf33daetemperature, shape=(30, 180, 180), dtype=float64, chunksize=(10, 180, 180), chunktype=numpy.ndarray>\n Coordinates:\n * time (time) datetime64[ns] 2015-01-01 2015-01-02 ... 2015-01-30\n * longitude (longitude) int64 0 1 2 3 4 5 6 7 ... 173 174 175 176 177 178 179\n * latitude (latitude) float64 89.5 88.5 87.5 86.5 ... -87.5 -88.5 -89.5\n
Once you\u2019ve manipulated a Dask array, you can still write a dataset too big to\n", "details": [{"source1": "html2text {}", "source2": "html2text {}", "unified_diff": "@@ -114,15 +114,15 @@\n You\u00e2\u0080\u0099ll notice that printing a dataset still shows a preview of array values,\n even if they are actually Dask arrays. We can do this quickly with Dask because\n we only need to compute the first few values (typically from the first block).\n To reveal the true nature of an array, print a DataArray:\n In [3]: ds.temperature\n Out[3]:\n ds.pipe(func)
) instead of\n simply calling it (e.g., func(ds)
). This allows you to write pipelines for\n transforming your data (using \u201cmethod chaining\u201d) instead of writing hard to\n follow nested function calls:
# these lines are equivalent, but with pipe we can make the logic flow\n # entirely from left to right\n In [60]: plt.plot((2 * ds.temperature.sel(x=0)).mean("y"))\n-Out[60]: [<matplotlib.lines.Line2D at 0xffff88655e80>]\n+Out[60]: [<matplotlib.lines.Line2D at 0xffff689d4fa0>]\n \n In [61]: (ds.temperature.sel(x=0).pipe(lambda x: 2 * x).mean("y").pipe(plt.plot))\n-Out[61]: [<matplotlib.lines.Line2D at 0xffff886611c0>]\n+Out[61]: [<matplotlib.lines.Line2D at 0xffff689df2e0>]\n
Both pipe
and assign
replicate the pandas methods of the same names\n (DataFrame.pipe
and\n DataFrame.assign
).
With xarray, there is no performance penalty for creating new datasets, even if\n variables are lazily loaded from a file on disk. Creating new objects instead\n", "details": [{"source1": "html2text {}", "source2": "html2text {}", "unified_diff": "@@ -619,19 +619,19 @@\n There is also the pipe() method that allows you to use a method call with an\n external function (e.g., ds.pipe(func)) instead of simply calling it (e.g.,\n func(ds)). This allows you to write pipelines for transforming your data (using\n \u00e2\u0080\u009cmethod chaining\u00e2\u0080\u009d) instead of writing hard to follow nested function calls:\n # these lines are equivalent, but with pipe we can make the logic flow\n # entirely from left to right\n In [60]: plt.plot((2 * ds.temperature.sel(x=0)).mean(\"y\"))\n-Out[60]: [ Let\u2019s create a simple plot of 2-m air temperature in degrees Celsius: Write equations to calculate the vertical coordinate. These will be only evaluated when data is requested. Information about the ROMS vertical coordinate can be found (here)[https://www.myroms.org/wiki/Vertical_S-coordinate] In short, for The function we will apply is Plot the first timestep: We first have to come up with the weights, - calculate the month lengths for each monthly data record - calculate weights using Finally, we just need to multiply our weights by the In this example, the logical coordinates are Control the map projection parameters on multiple axes This example illustrates how to plot multiple maps and control their extent and aspect ratio. For more details see this discussion on github. Additional keyword arguments can be passed to scipy\u2019s functions. (The suffix [3]:\n
Add a lazilly calculated vertical coordinates\u00b6
\n Vtransform==2
as used in this example,np.interp
which expects 1D numpy arrays. This functionality is already implemented in xarray so we use that capability to make sure we are not making mistakes.[2]:\n
[3]:\n
Now for the heavy lifting:\u00b6
\n groupby('time.season')
Dataset
and sum allong the time dimension. Creating a DataArray
for the month length is as easy as using the days_in_month
accessor on the time coordinate. The calendar type, in this case 'noleap'
, is automatically considered in this operation.x
and y
, while the physical coordinates are xc
and yc
, which represent the latitudes and longitude of the data.[3]:\n
Multiple plots and map projections\u00b6
\n <xarray.Dataset>\n Dimensions: (location: 3, time: 731)\n Coordinates:\n * time (time) datetime64[ns] 2000-01-01 2000-01-02 ... 2001-12-31\n * location (location) <U2 'IA' 'IN' 'IL'\n Data variables:\n tmin (time, location) float64 -8.037 -1.788 -3.932 ... -1.346 -4.544\n- tmax (time, location) float64 12.98 3.31 6.779 ... 6.636 3.343 3.805
array(['2000-01-01T00:00:00.000000000', '2000-01-02T00:00:00.000000000',\n+ tmax (time, location) float64 12.98 3.31 6.779 ... 6.636 3.343 3.805
array(['2000-01-01T00:00:00.000000000', '2000-01-02T00:00:00.000000000',\n '2000-01-03T00:00:00.000000000', ..., '2001-12-29T00:00:00.000000000',\n '2001-12-30T00:00:00.000000000', '2001-12-31T00:00:00.000000000'],\n- dtype='datetime64[ns]')
array(['IA', 'IN', 'IL'], dtype='<U2')
array([[ -8.03736932, -1.78844117, -3.93154201],\n+ dtype='datetime64[ns]')
array(['IA', 'IN', 'IL'], dtype='<U2')
array([[ -8.03736932, -1.78844117, -3.93154201],\n [ -9.34115662, -6.55807323, 0.13203714],\n [-12.13971902, -6.14641918, -1.06187252],\n ...,\n [ -5.34723825, -13.37459826, -4.93221199],\n [ -2.67283594, -5.18072141, -4.11567869],\n- [ 2.06327582, -1.34576404, -4.54392729]])
array([[12.98054898, 3.31040942, 6.77855382],\n+ [ 2.06327582, -1.34576404, -4.54392729]])
array([[12.98054898, 3.31040942, 6.77855382],\n [ 0.44785582, 6.37271154, 4.8434966 ],\n [ 5.32269851, 6.25176289, 5.98033045],\n ...,\n [ 6.73078492, 7.74795302, 8.04569651],\n [ 6.46376911, 6.31695352, 1.55799171],\n- [ 6.63593435, 3.34271537, 3.80527925]])
Examine a dataset with pandas and seaborn\u00b6
\n Convert to a pandas DataFrame\u00b6
\n [2]:\n@@ -1112,15 +1112,15 @@\n
[5]:\n
\n-<seaborn.axisgrid.PairGrid at 0xffff965173a0>\n+<seaborn.axisgrid.PairGrid at 0xffff9745ecd0>\n
array([[0.9516129 , 0.88709677, 0.93548387],\n+ * month (month) int64 1 2 3 4 5 6 7 8 9 10 11 12
array([[0.9516129 , 0.88709677, 0.93548387],\n [0.84210526, 0.71929825, 0.77192982],\n [0.24193548, 0.12903226, 0.16129032],\n [0. , 0. , 0. ],\n [0. , 0. , 0. ],\n [0. , 0. , 0. ],\n [0. , 0. , 0. ],\n [0. , 0. , 0. ],\n [0. , 0. , 0. ],\n [0. , 0.01612903, 0. ],\n [0.33333333, 0.35 , 0.23333333],\n- [0.93548387, 0.85483871, 0.82258065]])
array(['IA', 'IN', 'IL'], dtype='<U2')
array([ 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12])
array(['IA', 'IN', 'IL'], dtype='<U2')
array([ 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12])
[7]:\n
\n freeze.to_pandas().plot()\n@@ -2025,18 +2025,18 @@\n Dimensions: (location: 3, time: 731)\n Coordinates:\n * time (time) datetime64[ns] 2000-01-01 2000-01-02 ... 2001-12-31\n * location (location) object 'IA' 'IN' 'IL'\n month (time) int64 1 1 1 1 1 1 1 1 1 ... 12 12 12 12 12 12 12 12 12\n Data variables:\n some_missing (time, location) float64 nan nan nan ... 2.063 -1.346 -4.544\n- filled (time, location) float64 -5.163 -4.216 ... -1.346 -4.544
array(['2000-01-01T00:00:00.000000000', '2000-01-02T00:00:00.000000000',\n+ filled (time, location) float64 -5.163 -4.216 ... -1.346 -4.544
array(['2000-01-01T00:00:00.000000000', '2000-01-02T00:00:00.000000000',\n '2000-01-03T00:00:00.000000000', ..., '2001-12-29T00:00:00.000000000',\n '2001-12-30T00:00:00.000000000', '2001-12-31T00:00:00.000000000'],\n- dtype='datetime64[ns]')
array(['IA', 'IN', 'IL'], dtype=object)
array([ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,\n+ dtype='datetime64[ns]')
array(['IA', 'IN', 'IL'], dtype=object)
array([ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,\n 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 2, 2, 2,\n 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,\n 2, 2, 2, 2, 2, 2, 2, 2, 2, 3, 3, 3, 3, 3, 3, 3, 3,\n 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3,\n 3, 3, 3, 3, 3, 3, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4,\n 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4,\n 4, 4, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5,\n@@ -2068,27 +2068,27 @@\n 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 9, 9, 9,\n 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9,\n 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 10, 10, 10, 10, 10, 10, 10,\n 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10,\n 10, 10, 10, 10, 10, 10, 10, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11,\n 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11,\n 11, 11, 11, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12,\n- 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12])
array([[ nan, nan, nan],\n+ 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12])
array([[ nan, nan, nan],\n [ nan, nan, nan],\n [ nan, nan, nan],\n ...,\n [ -5.34723825, -13.37459826, -4.93221199],\n [ -2.67283594, -5.18072141, -4.11567869],\n- [ 2.06327582, -1.34576404, -4.54392729]])
array([[ -5.16274935, -4.21616663, -4.68137385],\n+ [ 2.06327582, -1.34576404, -4.54392729]])
array([[ -5.16274935, -4.21616663, -4.68137385],\n [ -5.16274935, -4.21616663, -4.68137385],\n [ -5.16274935, -4.21616663, -4.68137385],\n ...,\n [ -5.34723825, -13.37459826, -4.93221199],\n [ -2.67283594, -5.18072141, -4.11567869],\n- [ 2.06327582, -1.34576404, -4.54392729]])
[12]:\n
\n df = both.sel(time="2000").mean("location").reset_coords(drop=True).to_dataframe()\n", "details": [{"source1": "html2text {}", "source2": "html2text {}", "unified_diff": "@@ -188,15 +188,15 @@\n [4]:\n
array([[0.9516129 , 0.88709677, 0.93548387],\\n\",\n+ \" * month (month) int64 1 2 3 4 5 6 7 8 9 10 11 12
array([[0.9516129 , 0.88709677, 0.93548387],\\n\",\n \" [0.84210526, 0.71929825, 0.77192982],\\n\",\n \" [0.24193548, 0.12903226, 0.16129032],\\n\",\n \" [0. , 0. , 0. ],\\n\",\n \" [0. , 0. , 0. ],\\n\",\n \" [0. , 0. , 0. ],\\n\",\n \" [0. , 0. , 0. ],\\n\",\n \" [0. , 0. , 0. ],\\n\",\n \" [0. , 0. , 0. ],\\n\",\n \" [0. , 0.01612903, 0. ],\\n\",\n \" [0.33333333, 0.35 , 0.23333333],\\n\",\n- \" [0.93548387, 0.85483871, 0.82258065]])
array(['IA', 'IN', 'IL'], dtype='<U2')
array([ 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12])
array(['IA', 'IN', 'IL'], dtype='<U2')
array([ 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12])
array(['2000-01-01T00:00:00.000000000', '2000-01-02T00:00:00.000000000',\\n\",\n+ \" filled (time, location) float64 -5.163 -4.216 ... -1.346 -4.544
array(['2000-01-01T00:00:00.000000000', '2000-01-02T00:00:00.000000000',\\n\",\n \" '2000-01-03T00:00:00.000000000', ..., '2001-12-29T00:00:00.000000000',\\n\",\n \" '2001-12-30T00:00:00.000000000', '2001-12-31T00:00:00.000000000'],\\n\",\n- \" dtype='datetime64[ns]')
array(['IA', 'IN', 'IL'], dtype=object)
array([ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,\\n\",\n+ \" dtype='datetime64[ns]')
array(['IA', 'IN', 'IL'], dtype=object)
array([ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,\\n\",\n \" 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 2, 2, 2,\\n\",\n \" 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,\\n\",\n \" 2, 2, 2, 2, 2, 2, 2, 2, 2, 3, 3, 3, 3, 3, 3, 3, 3,\\n\",\n \" 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3,\\n\",\n \" 3, 3, 3, 3, 3, 3, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4,\\n\",\n \" 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4,\\n\",\n \" 4, 4, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5,\\n\",\n@@ -1803,27 +1803,27 @@\n \" 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 9, 9, 9,\\n\",\n \" 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9,\\n\",\n \" 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 10, 10, 10, 10, 10, 10, 10,\\n\",\n \" 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10,\\n\",\n \" 10, 10, 10, 10, 10, 10, 10, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11,\\n\",\n \" 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11,\\n\",\n \" 11, 11, 11, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12,\\n\",\n- \" 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12])
array([[ nan, nan, nan],\\n\",\n+ \" 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12])
array([[ nan, nan, nan],\\n\",\n \" [ nan, nan, nan],\\n\",\n \" [ nan, nan, nan],\\n\",\n \" ...,\\n\",\n \" [ -5.34723825, -13.37459826, -4.93221199],\\n\",\n \" [ -2.67283594, -5.18072141, -4.11567869],\\n\",\n- \" [ 2.06327582, -1.34576404, -4.54392729]])
array([[ -5.16274935, -4.21616663, -4.68137385],\\n\",\n+ \" [ 2.06327582, -1.34576404, -4.54392729]])
array([[ -5.16274935, -4.21616663, -4.68137385],\\n\",\n \" [ -5.16274935, -4.21616663, -4.68137385],\\n\",\n \" [ -5.16274935, -4.21616663, -4.68137385],\\n\",\n \" ...,\\n\",\n \" [ -5.34723825, -13.37459826, -4.93221199],\\n\",\n \" [ -2.67283594, -5.18072141, -4.11567869],\\n\",\n- \" [ 2.06327582, -1.34576404, -4.54392729]])
# fill 0 for the outside of the original coordinates.\n In [21]: da.interp(x=np.linspace(-0.5, 1.5, 10), kwargs={"fill_value": 0.0})\n Out[21]: \n@@ -611,15 +611,15 @@\n /build/reproducible-path/python-xarray-0.16.2/xarray/tutorial.py in open_dataset(name, cache, cache_dir, github_url, branch, **kws)\n 76 # May want to add an option to remove it.\n 77 if not _os.path.isdir(longdir):\n ---> 78 _os.mkdir(longdir)\n 79 \n 80 url = "/".join((github_url, "raw", branch, fullname))\n \n-FileNotFoundError: [Errno 2] No such file or directory: '/nonexistent/first-build/.xarray_tutorial_data'\n+FileNotFoundError: [Errno 2] No such file or directory: '/nonexistent/second-build/.xarray_tutorial_data'\n \n In [45]: fig, axes = plt.subplots(ncols=2, figsize=(10, 4))\n \n In [46]: ds.air.plot(ax=axes[0])\n ---------------------------------------------------------------------------\n AttributeError Traceback (most recent call last)\n <ipython-input-46-cb8f083667be> in <module>\n", "details": [{"source1": "html2text {}", "source2": "html2text {}", "unified_diff": "@@ -202,26 +202,26 @@\n ....: np.sin(np.linspace(0, 2 * np.pi, 10)),\n ....: dims=\"x\",\n ....: coords={\"x\": np.linspace(0, 1, 10)},\n ....: )\n ....:\n \n In [17]: da.plot.line(\"o\", label=\"original\")\n-Out[17]: [
.zarr
is optional\u2013just a reminder that a zarr store lives\n there.) If the directory does not exist, it will be created. If a zarr\n store is already present at that path, an error will be raised, preventing it\n from being overwritten. To override this behavior and overwrite an existing\n store, add mode='w'
when invoking to_zarr()
.to_zarr
method as variable encoding.\n For example:
In [42]: import zarr\n \n In [43]: compressor = zarr.Blosc(cname="zstd", clevel=3, shuffle=2)\n \n In [44]: ds.to_zarr("foo.zarr", encoding={"foo": {"compressor": compressor}})\n-Out[44]: <xarray.backends.zarr.ZarrStore at 0xffff57542400>\n+Out[44]: <xarray.backends.zarr.ZarrStore at 0xffff4074e520>\n
Note
\nNot all native zarr compression and filtering options have been tested with\n xarray.
\nFinally, you can use region
to write to limited regions of existing arrays\n in an existing Zarr store. This is a good option for writing data in parallel\n from independent processes.
To scale this up to writing large datasets, the first step is creating an\n initial Zarr store without writing all of its array data. This can be done by\n@@ -1218,33 +1218,33 @@\n \n In [51]: ds = xr.Dataset({"foo": ("x", dummies)})\n \n In [52]: path = "path/to/directory.zarr"\n \n # Now we write the metadata without computing any array values\n In [53]: ds.to_zarr(path, compute=False, consolidated=True)\n-Out[53]: Delayed('_finalize_store-03d2aeb5-469e-4639-96ca-4f833ed6b714')\n+Out[53]: Delayed('_finalize_store-aa004604-7456-43e7-a304-cbd78eb3f262')\n \n \n
Now, a Zarr store with the correct variable shapes and attributes exists that\n can be filled out by subsequent calls to to_zarr
. The region
provides a\n mapping from dimension names to Python slice
objects indicating where the\n data should be written (in index space, not coordinate space), e.g.,
# For convenience, we'll slice a single dataset, but in the real use-case\n # we would create them separately, possibly even from separate processes.\n In [54]: ds = xr.Dataset({"foo": ("x", np.arange(30))})\n \n In [55]: ds.isel(x=slice(0, 10)).to_zarr(path, region={"x": slice(0, 10)})\n-Out[55]: <xarray.backends.zarr.ZarrStore at 0xffff5752cc40>\n+Out[55]: <xarray.backends.zarr.ZarrStore at 0xffff4074eac0>\n \n In [56]: ds.isel(x=slice(10, 20)).to_zarr(path, region={"x": slice(10, 20)})\n-Out[56]: <xarray.backends.zarr.ZarrStore at 0xffff57542ca0>\n+Out[56]: <xarray.backends.zarr.ZarrStore at 0xffff4074e700>\n \n In [57]: ds.isel(x=slice(20, 30)).to_zarr(path, region={"x": slice(20, 30)})\n-Out[57]: <xarray.backends.zarr.ZarrStore at 0xffff886f31c0>\n+Out[57]: <xarray.backends.zarr.ZarrStore at 0xffff68a71340>\n
Concurrent writes with region
are safe as long as they modify distinct\n chunks in the underlying Zarr arrays (or use an appropriate lock
).
As a safety check to make it harder to inadvertently override existing values,\n if you set Since this is a thin wrapper around matplotlib, all the functionality of\n@@ -1314,56 +1314,56 @@\n Data variables:\n A (x, y, z, w) float64 -0.104 0.02719 -0.0425 ... -0.1175 -0.0183\n B (x, y, z, w) float64 0.0 0.0 0.0 0.0 ... 1.369 1.408 1.387 1.417\n Suppose we want to scatter The When The Faceting is also possible For more advanced scatter plots, we recommend converting the relevant data variables to a pandas DataFrame and using the extensive plotting capabilities of The plot will produce an image corresponding to the values of the array.\n Hence the top left pixel will be a different color than the others.\n Before reading on, you may want to look at the coordinates and\n think carefully about what the limits, labels, and orientation for\n each of the axes should be. It may seem strange that\n the values on the y axis are decreasing with -0.5 on the top. This is because\n the pixels are centered over their coordinates, and the\n axis labels and ranges correspond to the values of the\n@@ -1572,81 +1572,81 @@\n .....: np.arange(20).reshape(4, 5),\n .....: dims=["y", "x"],\n .....: coords={"lat": (("y", "x"), lat), "lon": (("y", "x"), lon)},\n .....: )\n .....: \n \n In [127]: da.plot.pcolormesh("lon", "lat")\n-Out[127]: <matplotlib.collections.QuadMesh at 0xffffae3e6c70>\n+Out[127]: <matplotlib.collections.QuadMesh at 0xffff82de7610>\n \n \n \n Note that in this case, xarray still follows the pixel centered convention.\n This might be undesirable in some cases, for example when your data is defined\n on a polar projection (GH781). This is why the default is to not follow\n this convention when plotting on a map: You can however decide to infer the cell boundaries and use the\n Note The data model of xarray does not support datasets with cell boundaries\n yet. If you want to use these coordinates, you\u2019ll have to make the plots\n outside the xarray framework. One can also make line plots with multidimensional coordinates. In this case, Visualizing your datasets is quick and convenient: Note the automatic labeling with names and units. Our effort in adding metadata attributes has paid off! Many aspects of these figures are customizable: see Plotting. New Added new methods New region
then all variables included in a Dataset must have\n dimensions included in region
. Other variables (typically coordinates)\n", "details": [{"source1": "html2text {}", "source2": "html2text {}", "unified_diff": "@@ -762,15 +762,15 @@\n ....: \"y\": pd.date_range(\"2000-01-01\", periods=5),\n ....: \"z\": (\"x\", list(\"abcd\")),\n ....: },\n ....: )\n ....:\n \n In [39]: ds.to_zarr(\"path/to/directory.zarr\")\n-Out[39]: Calling Matplotlib\u00b6
\n A
against B
In [95]: ds.plot.scatter(x="A", y="B")\n-Out[95]: <matplotlib.collections.PathCollection at 0xffff570bd760>\n+Out[95]: <matplotlib.collections.PathCollection at 0xffff402f9580>\n
hue
kwarg lets you vary the color by variable valueIn [96]: ds.plot.scatter(x="A", y="B", hue="w")\n Out[96]: \n-[<matplotlib.collections.PathCollection at 0xffff6c7d9760>,\n- <matplotlib.collections.PathCollection at 0xffff6c7d9f70>,\n- <matplotlib.collections.PathCollection at 0xffff6c3df6d0>,\n- <matplotlib.collections.PathCollection at 0xffff57521cd0>]\n+[<matplotlib.collections.PathCollection at 0xffff682bbe80>,\n+ <matplotlib.collections.PathCollection at 0xffff688c7100>,\n+ <matplotlib.collections.PathCollection at 0xffff6acc2df0>,\n+ <matplotlib.collections.PathCollection at 0xffff6812a580>]\n
hue
is specified, a colorbar is added for numeric hue
DataArrays by\n default and a legend is added for non-numeric hue
DataArrays (as above).\n You can force a legend instead of a colorbar by setting hue_style='discrete'
.\n Additionally, the boolean kwarg add_guide
can be used to prevent the display of a legend or colorbar (as appropriate).In [97]: ds = ds.assign(w=[1, 2, 3, 5])\n \n In [98]: ds.plot.scatter(x="A", y="B", hue="w", hue_style="discrete")\n Out[98]: \n-[<matplotlib.collections.PathCollection at 0xffff6c08c6a0>,\n- <matplotlib.collections.PathCollection at 0xffff6c0e0250>,\n- <matplotlib.collections.PathCollection at 0xffff6c076b50>,\n- <matplotlib.collections.PathCollection at 0xffff6c0b6af0>]\n+[<matplotlib.collections.PathCollection at 0xffff68277040>,\n+ <matplotlib.collections.PathCollection at 0xffff582932b0>,\n+ <matplotlib.collections.PathCollection at 0xffff5836ff10>,\n+ <matplotlib.collections.PathCollection at 0xffff690cc430>]\n
markersize
kwarg lets you vary the point\u2019s size by variable value. You can additionally pass size_norm
to control how the variable\u2019s values are mapped to point sizes.In [99]: ds.plot.scatter(x="A", y="B", hue="z", hue_style="discrete", markersize="z")\n Out[99]: \n-[<matplotlib.collections.PathCollection at 0xffff56f20520>,\n- <matplotlib.collections.PathCollection at 0xffff57555970>,\n- <matplotlib.collections.PathCollection at 0xffff56f8dc70>,\n- <matplotlib.collections.PathCollection at 0xffff570e7760>]\n+[<matplotlib.collections.PathCollection at 0xffff585f61c0>,\n+ <matplotlib.collections.PathCollection at 0xffff40241640>,\n+ <matplotlib.collections.PathCollection at 0xffff68d013a0>,\n+ <matplotlib.collections.PathCollection at 0xffff40241e80>]\n
In [100]: ds.plot.scatter(x="A", y="B", col="x", row="z", hue="w", hue_style="discrete")\n-Out[100]: <xarray.plot.facetgrid.FacetGrid at 0xffff56f5dd30>\n+Out[100]: <xarray.plot.facetgrid.FacetGrid at 0xffff40100160>\n
seaborn
.Maps\u00b6
\n@@ -1380,15 +1380,15 @@\n /build/reproducible-path/python-xarray-0.16.2/xarray/tutorial.py in open_dataset(name, cache, cache_dir, github_url, branch, **kws)\n 76 # May want to add an option to remove it.\n 77 if not _os.path.isdir(longdir):\n ---> 78 _os.mkdir(longdir)\n 79 \n 80 url = "/".join((github_url, "raw", branch, fullname))\n \n-FileNotFoundError: [Errno 2] No such file or directory: '/nonexistent/first-build/.xarray_tutorial_data'\n+FileNotFoundError: [Errno 2] No such file or directory: '/nonexistent/second-build/.xarray_tutorial_data'\n \n In [103]: p = air.isel(time=0).plot(\n .....: subplot_kws=dict(projection=ccrs.Orthographic(-80, 35), facecolor="gray"),\n .....: transform=ccrs.PlateCarree(),\n .....: )\n .....: \n ---------------------------------------------------------------------------\n@@ -1472,24 +1472,24 @@\n In [109]: import xarray.plot as xplt\n \n In [110]: da = xr.DataArray(range(5))\n \n In [111]: fig, axes = plt.subplots(ncols=2, nrows=2)\n \n In [112]: da.plot(ax=axes[0, 0])\n-Out[112]: [<matplotlib.lines.Line2D at 0xffff56cea4f0>]\n+Out[112]: [<matplotlib.lines.Line2D at 0xffff2b6d8df0>]\n \n In [113]: da.plot.line(ax=axes[0, 1])\n-Out[113]: [<matplotlib.lines.Line2D at 0xffff6c0ef160>]\n+Out[113]: [<matplotlib.lines.Line2D at 0xffff82dc2af0>]\n \n In [114]: xplt.plot(da, ax=axes[1, 0])\n-Out[114]: [<matplotlib.lines.Line2D at 0xffff56cd5e80>]\n+Out[114]: [<matplotlib.lines.Line2D at 0xffff2b6d8430>]\n \n In [115]: xplt.line(da, ax=axes[1, 1])\n-Out[115]: [<matplotlib.lines.Line2D at 0xffff56cd5940>]\n+Out[115]: [<matplotlib.lines.Line2D at 0xffff2b663dc0>]\n \n In [116]: plt.tight_layout()\n \n In [117]: plt.draw()\n
In [122]: a.plot()\n-Out[122]: <matplotlib.collections.QuadMesh at 0xffff56d273a0>\n+Out[122]: <matplotlib.collections.QuadMesh at 0xffff2b731700>\n
In [128]: import cartopy.crs as ccrs\n \n In [129]: ax = plt.subplot(projection=ccrs.PlateCarree())\n \n In [130]: da.plot.pcolormesh("lon", "lat", ax=ax)\n-Out[130]: <matplotlib.collections.QuadMesh at 0xffff6c3a67f0>\n+Out[130]: <matplotlib.collections.QuadMesh at 0xffff402ea850>\n \n In [131]: ax.scatter(lon, lat, transform=ccrs.PlateCarree())\n-Out[131]: <matplotlib.collections.PathCollection at 0xffff56c8f5b0>\n+Out[131]: <matplotlib.collections.PathCollection at 0xffff82f86130>\n \n In [132]: ax.coastlines()\n-Out[132]: <cartopy.mpl.feature_artist.FeatureArtist at 0xffffae50cf10>\n+Out[132]: <cartopy.mpl.feature_artist.FeatureArtist at 0xffff582934f0>\n \n In [133]: ax.gridlines(draw_labels=True)\n-Out[133]: <cartopy.mpl.gridliner.Gridliner at 0xffffae50ca30>\n+Out[133]: <cartopy.mpl.gridliner.Gridliner at 0xffff58293af0>\n
infer_intervals
keyword:In [134]: ax = plt.subplot(projection=ccrs.PlateCarree())\n \n In [135]: da.plot.pcolormesh("lon", "lat", ax=ax, infer_intervals=True)\n-Out[135]: <matplotlib.collections.QuadMesh at 0xffffae57ea00>\n+Out[135]: <matplotlib.collections.QuadMesh at 0xffff82fd67c0>\n \n In [136]: ax.scatter(lon, lat, transform=ccrs.PlateCarree())\n-Out[136]: <matplotlib.collections.PathCollection at 0xffffae57e3d0>\n+Out[136]: <matplotlib.collections.PathCollection at 0xffff2b376730>\n \n In [137]: ax.coastlines()\n-Out[137]: <cartopy.mpl.feature_artist.FeatureArtist at 0xffff5695ad60>\n+Out[137]: <cartopy.mpl.feature_artist.FeatureArtist at 0xffff2b3ac790>\n \n In [138]: ax.gridlines(draw_labels=True)\n-Out[138]: <cartopy.mpl.gridliner.Gridliner at 0xffff5695ad30>\n+Out[138]: <cartopy.mpl.gridliner.Gridliner at 0xffff2b3acc70>\n
hue
must be a dimension name, not a coordinate name.In [139]: f, ax = plt.subplots(2, 1)\n \n In [140]: da.plot.line(x="lon", hue="y", ax=ax[0])\n Out[140]: \n-[<matplotlib.lines.Line2D at 0xffff57525280>,\n- <matplotlib.lines.Line2D at 0xffff56c54dc0>,\n- <matplotlib.lines.Line2D at 0xffff56d1a8b0>,\n- <matplotlib.lines.Line2D at 0xffff570f30a0>]\n+[<matplotlib.lines.Line2D at 0xffff82ef1d90>,\n+ <matplotlib.lines.Line2D at 0xffff58589b20>,\n+ <matplotlib.lines.Line2D at 0xffff40067fa0>,\n+ <matplotlib.lines.Line2D at 0xffff82f865e0>]\n \n In [141]: da.plot.line(x="lon", hue="x", ax=ax[1])\n Out[141]: \n-[<matplotlib.lines.Line2D at 0xffff56882160>,\n- <matplotlib.lines.Line2D at 0xffff56882400>,\n- <matplotlib.lines.Line2D at 0xffff56882460>,\n- <matplotlib.lines.Line2D at 0xffff568825b0>,\n- <matplotlib.lines.Line2D at 0xffff56882670>]\n+[<matplotlib.lines.Line2D at 0xffff2b292220>,\n+ <matplotlib.lines.Line2D at 0xffff2b292b80>,\n+ <matplotlib.lines.Line2D at 0xffff2b292be0>,\n+ <matplotlib.lines.Line2D at 0xffff2b292d30>,\n+ <matplotlib.lines.Line2D at 0xffff2b292df0>]\n
Plotting\u00b6
\n In [37]: data.plot()\n-Out[37]: <matplotlib.collections.QuadMesh at 0xffff567e1e50>\n+Out[37]: <matplotlib.collections.QuadMesh at 0xffff2b1f8610>\n
pandas\u00b6
\n", "details": [{"source1": "html2text {}", "source2": "html2text {}", "unified_diff": "@@ -304,15 +304,15 @@\n [0.787, 0. , 1.199]])\n Coordinates:\n * x (x) int64 10 20\n Dimensions without coordinates: y\n ***** Plotting\u00c2\u00b6 *****\n Visualizing your datasets is quick and convenient:\n In [37]: data.plot()\n-Out[37]: xray.Dataset.where
method for masking xray objects according\n to some criteria. This works particularly well with multi-dimensional data:In [44]: ds = xray.Dataset(coords={"x": range(100), "y": range(100)})\n \n In [45]: ds["distance"] = np.sqrt(ds.x ** 2 + ds.y ** 2)\n \n In [46]: ds.distance.where(ds.distance < 100).plot()\n-Out[46]: <matplotlib.collections.QuadMesh at 0xffff5679fc10>\n+Out[46]: <matplotlib.collections.QuadMesh at 0xffff2a3553d0>\n
xray.DataArray.diff
and xray.Dataset.diff
\n for finite difference calculations along a given axis.xray.DataArray.to_masked_array
convenience method for\n", "details": [{"source1": "html2text {}", "source2": "html2text {}", "unified_diff": "@@ -2957,15 +2957,15 @@\n * New xray.Dataset.where method for masking xray objects according to some\n criteria. This works particularly well with multi-dimensional data:\n In [44]: ds = xray.Dataset(coords={\"x\": range(100), \"y\": range(100)})\n \n In [45]: ds[\"distance\"] = np.sqrt(ds.x ** 2 + ds.y ** 2)\n \n In [46]: ds.distance.where(ds.distance < 100).plot()\n- Out[46]: