2017-12-05 1 views
0

계절 https://github.com/welch/seasonal의 "예제 사용"을 시도했습니다. 코드는 다음과 같습니다.계절과 계절에 따라 달라지는 추세와 차이점은 무엇입니까?

import math 
from seasonal import fit_seasons,adjust_seasons 
import pandas as pd 
import matplotlib.pyplot as plt 
import numpy as np 

s = [10 * math.sin(i * 2 * math.pi/25) + i * i /100.0 for i in range(100)] 
seasons,trend = fit_seasons(s) 

adjusted = adjust_seasons(s,seasons=seasons) 

residual = adjusted -trend 

조정 및 추세의 차이점은 무엇입니까?

답변

0

"계절적으로 조정 된"데이터입니다. 즉 계절 성분이 추출 된 데이터이다. 신호가 Y이고 분해도가 Y = S + T + R 인 경우 S이 계절 구성 요소 인 경우 T이 추세이고 R이 나머지 일 경우 "계절적으로 조정 된"결과는 단지 T + R입니다.

관련 문제