ee.Image.matrixDiagonal
Computes the diagonal of the matrix in a single column.
Usage | Returns |
---|
Image.matrixDiagonal() | Image |
Argument | Type | Details |
---|
this: value | Image | The image to which the operation is applied. |
Except as otherwise noted, the content of this page is licensed under the Creative Commons Attribution 4.0 License, and code samples are licensed under the Apache 2.0 License. For details, see the Google Developers Site Policies. Java is a registered trademark of Oracle and/or its affiliates.
Last updated 2023-10-06 UTC.
[null,null,["Last updated 2023-10-06 UTC."],[[["This operation computes the diagonal of an image matrix and returns it as a single column in a new image."],["It's applicable to image data and can be accessed using `Image.matrixDiagonal()`."],["The input is an image, and the output is a new image containing the diagonal elements."]]],["The `matrixDiagonal()` function extracts the diagonal elements of a matrix within an image. It takes an image as input and returns a new image containing the diagonal values arranged in a single column. The operation is applied directly to the input image. The function doesn't require any additional arguments.\n"]]