我试图使波浪更平滑(从股票价格),但我不知道如何将它应用到我的波浪中。
import numpy as np
wave = [1575.7918235085228, 1574.2183726917613, 1571.9212868430398, 1569.5071067116478, 1568.4249178799716, 1567.4649192116478, 1566.7141801313921, 1565.9849054509943, 1565.4699951171874, 1566.766004527699, 1567.222733931108, 1567.4478271484375, 1566.3074729225852, 1563.4207475142045, 1559.6012806285512, 1555.0241965553978, 1552.6043723366477, 1550.9003773082386, 1549.0460116299716, 1548.2069202769887, 1549.2643687855114, 1551.792538174716, 1554.6467240767045, 1557.9874578302556, 1560.9547341086648, 1563.2614679509943, 1565.0818204012785, 1565.241825727983, 1565.4223677201705, 1566.1059992009943, 1566.3267223011364, 1566.7634410511364, 1566.691796875, 1567.2850763494318, 1567.2025368430398, 1566.6512761896306, 1567.7338201349432, 1569.591093306108, 1570.538554243608, 1571.8510919744317, 1573.8294588955966]
hamm = np.hamming(len(wave))
这是来自 aspen 程序的汉明移动平均线的示例图像 参考
我的波变量是绘图后的绿线。该程序具有对其应用汉明然后绘制红线的功能
所以我只想知道这个程序是怎么做的。
谢谢你。