mv_median.asciidoc 741 B

12345678910111213141516171819202122
  1. // This is generated by ESQL's AbstractFunctionTestCase. Do no edit it. See ../README.md for how to regenerate it.
  2. *Examples*
  3. [source.merge.styled,esql]
  4. ----
  5. include::{esql-specs}/math.csv-spec[tag=mv_median]
  6. ----
  7. [%header.monospaced.styled,format=dsv,separator=|]
  8. |===
  9. include::{esql-specs}/math.csv-spec[tag=mv_median-result]
  10. |===
  11. If the row has an even number of values for a column, the result will be the average of the middle two entries. If the column is not floating point, the average rounds *down*:
  12. [source.merge.styled,esql]
  13. ----
  14. include::{esql-specs}/math.csv-spec[tag=mv_median_round_down]
  15. ----
  16. [%header.monospaced.styled,format=dsv,separator=|]
  17. |===
  18. include::{esql-specs}/math.csv-spec[tag=mv_median_round_down-result]
  19. |===