simple-statsxq by Tim Thompson.
From the webpage:
Loosely inspired by the JavaScript simple-statistics project. The goal of this module is to provide a basic set of statistical functions for doing data analysis in XQuery 3.1.
Functions are intended to be implementation-agnostic.
Unit tests were written using the unit testing module of BaseX.
OpenFormula (Open Document Format for Office Applications (OpenDocument)) defines eighty-seven (87) statistical functions.
There are fifty-five (55) financial functions defined by OpenFormula, just in case you are interested.