Skip to content

Commit

Permalink
One more fix
Browse files Browse the repository at this point in the history
  • Loading branch information
dcherian committed Jul 11, 2024
1 parent 0db06ac commit 7902459
Showing 1 changed file with 0 additions and 18 deletions.
18 changes: 0 additions & 18 deletions xarray/core/computation.py
Original file line number Diff line number Diff line change
Expand Up @@ -1597,24 +1597,6 @@ def cross(
array([ 0, 0, -3])
Dimensions without coordinates: dim_0
One vector with different dimension order:
>>> a = xr.DataArray(
... [1, 2, 0],
... dims=["cartesian"],
... coords=dict(cartesian=(["cartesian"], ["x", "z", "y"])),
... )
>>> b = xr.DataArray(
... [4, 5, 6],
... dims=["cartesian"],
... coords=dict(cartesian=(["cartesian"], ["x", "y", "z"])),
... )
>>> xr.cross(a, b, dim="cartesian")
<xarray.DataArray (cartesian: 3)> Size: 24B
array([-10, 2, 5])
Coordinates:
* cartesian (cartesian) <U1 12B 'x' 'y' 'z'
Multiple vector cross-products. Note that the direction of the
cross product vector is defined by the right-hand rule:
Expand Down

0 comments on commit 7902459

Please sign in to comment.