What would be a good proxy for time?
조회 수: 4 (최근 30일)
이전 댓글 표시
In the previous post
I learned that one would need to consider confounding variables.
"Analysis reveals time to be the confounding variable: plotting both price and demand against time reveals the expected negative correlation over various periods, which then reverses to become positive if the influence of time is ignored by simply plotting demand against price."
So I want to use time as an indepedent variable of the regression.
I use dn=datenum(date) as a proxy. But is there any better method?
댓글 수: 0
채택된 답변
Raunak Gupta
2020년 12월 24일
Hi,
As I looked the discussion in above mentioned question link, I think it is more towards the correlation between two dependent variables with respect to time. Since you want to ignore time while calculating the correlation, if all the dependent variables are present for a given time stamp vector, they can be directly used in regression. For example.
If time is from t = 1 sec to 100 sec with interval of 1 sec and price and demand is available for each of those time value then price and demand can directly be used as two pair of vectors for calculating correlation.
Also, if the correlation between time and price, time and demand is meaningless, it is better to do regression between price and demand since it will show the correct trend.
댓글 수: 0
추가 답변 (0개)
참고 항목
카테고리
Help Center 및 File Exchange에서 Get Started with MATLAB에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!