I am interested in comparing a linear trend model with 1) power trend, 2) exponential trend, and 3) logarithmic trend models - comparing models using estimated AIC and BIC to identify the one that best fits my data.
I had a play with a sample dataset and wanted to make sure my models are well specified - grateful for any comment/suggestion for improvement:
clear
use http://www.stata-press.com/data/r16/friedman2.dta
* Create a time variable - rather than using the existing one (yearquarter)
g timen = _n
* Log variables
g ln_consum = log(consump)
g ln_time = log(timen)
* Linear trend model
regress consum timen
estat ic
* Exponential trend model
regress ln_consum timen
estat ic
* Power trend model
regress ln_consum ln_time
estat ic
* Logarithmic trend model
regress consum ln_time
estat ic
Related Posts with Trend analysis
Difference GMM, building valid instruments with X that is (mostly) time invariant.Hello, I have a theoretical question regarding the estimation of Difference GMM (Arellano Bond). I h…
Comparing coefficients in a regressionHi, I have the following linear regression model specified. These are at the consumer order level, i…
Simple Regression Questions: Time Series and % ChangeHello, I'm very much a Stata and linear regression newbie. I am running a linear regression with Bi…
Bayes factor in StataHi! I am working together with a colleague who has done a study with an amount of non significant fi…
Generating macro containing name of current do fileHello, Is there a way to do the above? I'm doing parallel analysis, with duplicate do files, except …
Subscribe to:
Post Comments (Atom)
0 Response to Trend analysis
Post a Comment