TALib Functions
TALib is used to add technical analysis to financial market trading applications. DolphinDB provides TALib functions for analysis in quantitative finance.
Introduction

Higherorder function talib:
talib(func, args...)
To process data starting with consecutive NULL values in the same way as Python TALib, you can call DolphinDB builtin functions with the higherorder function
talib
. 
Syntax template for the TALib functions:
TAlibFunc(X, window)
Parameters:
X is a vector/matrix/table.
window is a positive integer indicating the size of the sliding window.
List of Functions
 TALib functions provide a common template ma. You can specify the type of moving average with this function to implement the features of the following functions: sma, ema, wma, dema, tema, trima, kama, t3.
 Exponential moving average: wilder, gema
 Linear regression in sliding window: linearTimeTrend
Windowing Logic
The window size for TAlib functions is measured by the number of elements.
Different from other DolphinDB window functions, TAlib functions keep the NULL values at the beginning of data in the output. The calculation in the sliding window starts from the first nonNULL value.
Based on the calculation rules of the moving window functions, the calculation will be performed only when the elements fill the window, i.e., the result of the first window  1 element is NULL by default.
The following example calls msum
with talib
and the
figure shows how the windows slide:
X = NULL NULL NULL 1 2 3 4 5 6 NULL 8 9
w = 3 // window
print msum(X, w)
// output
[ , , , 1, 3, 6, 9, 12, 15, 11, 14, 17]
talib(msum, X, w)
// output
[ , , , , , 6, 9, 12, 15, 11, 14, 17]
The results of gray windows are NULL.