atan2.asciidoc 711 B

123456789101112131415161718192021222324252627282930313233343536
  1. [discrete]
  2. [[esql-atan2]]
  3. === `ATAN2`
  4. *Syntax*
  5. [.text-center]
  6. image::esql/functions/signature/atan2.svg[Embedded,opts=inline]
  7. *Parameters*
  8. `y`::
  9. Numeric expression. If `null`, the function returns `null`.
  10. `x`::
  11. Numeric expression. If `null`, the function returns `null`.
  12. *Description*
  13. The {wikipedia}/Atan2[angle] between the positive x-axis and the ray from the
  14. origin to the point (x , y) in the Cartesian plane, expressed in radians.
  15. *Supported types*
  16. include::types/atan2.asciidoc[]
  17. *Example*
  18. [source.merge.styled,esql]
  19. ----
  20. include::{esql-specs}/floats.csv-spec[tag=atan2]
  21. ----
  22. [%header.monospaced.styled,format=dsv,separator=|]
  23. |===
  24. include::{esql-specs}/floats.csv-spec[tag=atan2-result]
  25. |===