資源簡介
對數據進行活動窗口均值處理,根據其均值進行數據分類,具有時間連貫性。matlab代碼
代碼片段和文件信息
%——————————
%——————————時間序列分段PAA算法程序————————————
clear;
clc;
%——————————————參數輸入————————————%
A=input(‘Please?input?the?traffic?date?like?[6:00?6:30?···?]\n?A=‘);??%按照時間順序輸入交通流數據
[a?A_longth]=size(A);%采集交通流數據組數
fprintf(‘The?longth?of?the?input?is:%5.4g\n‘A_longth);%輸出交通流數據組數
fprintf(‘Attention?win_width>slide_steps\n‘);
M=input(‘Please?input?the?width?and?the?slide?step?of?the?slide?window\n?[win_width?slide_steps]=‘);%輸入滑動窗口大小及滑動步長
%——————————————參數處理————————————————%
win_width=M(1);%窗口大小
slide_steps=M(2);%滑動步長
- 上一篇:matlab通過腐蝕與膨脹提取圖像物體邊緣
- 下一篇:MATLAB桶形變換
評論
共有 條評論