Closed andy-k-improving closed 1 week ago
@andy-k-improving please add DCO (sign-off)
@andy-k-improving please add DCO (sign-off)
Done.
@andy-k-improving
please add the relevant documentation references including examples
Done.
@YANG-DB I have updated the example and documentation, would you mind to have another look?
Thanks,
Hi @dai-chen , @LantaoJin and @salyh , would you guys mind to have look on this, any feedback would be appreciated :)
The CI failure caused by https://github.com/opensearch-project/opensearch-spark/pull/903 is not related but blocks your whole testing process. @andy-k-improving could you merge the latest code from main?
Thanks for your contribution. Merging to main.
Description
Introduce a new variant (WMA) for existing trendline ppl command, by compositing a logical plan similar to the following with function
nth_value( )
to calculate the WMA value by perform event look behind.Some high level code changes:
TrendLine
processing logic, as sort field is mandatory for WMA calculation.TrendlineCatalystUtils.java
to have a new code path for WMA selection and associated calculation logic.Related Issues
Prior implement for SMA formula: https://github.com/opensearch-project/opensearch-spark/pull/833
Check List
--signoff
By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license. For more information on following Developer Certificate of Origin and signing off your commits, please check here.
Test plan:
Despite the existing unit test / integration test, the feature can also be tested manually, by first inserting a simple table, then run PPL trend line command against the table to calculate WMA value.