Documentation IndexFetch the complete documentation index at: /docs/llms.txtUse this file to discover all available pages before exploring further.
Fetch the complete documentation index at: /docs/llms.txt
Use this file to discover all available pages before exploring further.
入力値の移動和を計算します。
groupArrayMovingSum(numbers_for_summing) groupArrayMovingSum(window_size)(numbers_for_summing)
window_size
UInt64
numbers_for_summing
(U)Int*
Float*
Decimal
Array
CREATE TABLE t ( `int` UInt8, `float` Float32, `dec` Decimal32(2) ) ENGINE = Memory; INSERT INTO t VALUES (1, 1.1, 1.10), (2, 2.2, 2.20), (4, 4.4, 4.40), (7, 7.77, 7.77); SELECT groupArrayMovingSum(int) AS I, groupArrayMovingSum(float) AS F, groupArrayMovingSum(dec) AS D FROM t;
┌─I──────────┬─F───────────────────────────────────────────────────────────────────────────┬─D───────────────────┐ │ [1,3,7,14] │ [1.100000023841858,3.3000000715255737,7.700000166893005,15.470000147819519] │ [1.1,3.3,7.7,15.47] │ └────────────┴─────────────────────────────────────────────────────────────────────────────┴─────────────────────┘
SELECT groupArrayMovingSum(2)(int) AS I, groupArrayMovingSum(2)(float) AS F, groupArrayMovingSum(2)(dec) AS D FROM t;
┌─I──────────┬─F────────────────────────────────────────────────────────────────────────────┬─D───────────────────┐ │ [1,3,6,11] │ [1.100000023841858,3.3000000715255737,6.6000001430511475,12.170000076293945] │ [1.1,3.3,6.6,12.17] │ └────────────┴──────────────────────────────────────────────────────────────────────────────┴─────────────────────┘
このページは役に立ちましたか?