search for: tslag

Displaying 4 results from an estimated 4 matches for "tslag".

Did you mean: tflag
2003 Sep 25
1
Time Series DGPs
I was wondering if anyone had some sample time series dgp code. I am particularly interested in examples of autoregressive processes and error correction model DGPs. I have attached a more specific example of what I mean. I have tried myself but would hoping someone had some more elegant code that would help me extend my own code. Thanks Luke Keele UNC-Chapel Hill Nuffield College, Oxford
2012 Mar 20
1
MA process in panels
...)==i][1:n]<-rep(NA,n) } #I think I should now be able to use standard ARIMA methods such as res2<-arima(x=dem_yt,xreg=demXt,order=c(0,0,1)) #Alternatively, I tried to obtain res2 using maxLik() from the maxLik package, but I am not sure about how to specify the log-likelihood function: tslag <- function(x, d=l) { x <- as.vector(x) n <- length(x) c(rep(NA,d),x)[1:n] } log_Lik<-function(param) { b1<-param[1] b2<-param[2] b3<-param[3] sigma<-param[4] ll<- -0.5*N*log(2*pi) - N*log(sigma) - sum(0.5*(dem_yt-(b1*demXt[,1]+b2*demXt[,2]) + b3*tslag(dem_yt-(b1*d...
2002 Dec 09
1
heteroscedasticity analysis
Hello, First, sorry for my poor english, I will try to be understood. It's the first time I try this "r-help mailing list" and I hope it will be a success. I am working on heteroscedasticity analysis. I would like to get the "Box-Ljung" and the "Lagrange multipliers" test. I found the first one in the library "ts", but I can't find the second one.
2003 May 29
2
Newbie trying to Lag Variables in a regression
Perhaps I am making this too hard, but how does one regress y(t) on a constant, x(t-1) and y(t-1)? I've tried the manuals and until I get Dalgaard's book (just ordered on Amazon), I am stuck! Thanks to all in advance for your patience and consideration.