Hi team,

We are using tinkerpop Gremlin in our risk detection cases. Some analytical
calculations are used frequently, yet there is no corresponding steps in
hand.

I am thinking that some general analytical steps can be added in Gremlin.
e.g. steps to calculate standard deviation and percentile. The example
usage might be as follows.
--------------------------------
gremlin> g.V().values('ages')
==>1
==>2
==>3
gremlin> g.V().values('ages').stdev()
==>0.816
gremlin> g.V().values('ages').fold().stdev(Scope.local)
==>0.816

gremlin> g.V().values('ages').percentile(50)
==>2
// one percentile, return single value
gremlin> g.V().values('ages').percentile(0, 100)
==>[0: 1, 100: 3]
// multiple percentiles, return a map
--------------------------------

Sorry for not emailing earlier, I have created a JIRA ticket for this
https://issues.apache.org/jira/browse/TINKERPOP-2487.

As new steps are already used in our cases, we are glad to offer the
implementation for review, if you think it good to add the two steps.

Regards,
Junshi

Reply via email to