similar to: Kalman Filter - dlm package

Displaying 20 results from an estimated 100 matches similar to: "Kalman Filter - dlm package"

2007 Nov 24
0
Help on State-space modeling
Hi all, I'm working on a term structure estimation using state-space modeling for 1, 2 and 3 factor models. When I started to read the functions on R, I got to the function ss on the library sspir. From what I understood this function is similar to SsfFit from S-PLUS. But for my models purpose there is something left to be desired. Its formulation follow these equations: *Y_t = F_t^T *
2008 May 07
1
dlm with constant terms
Hi, I am trying to figure how to use dlm with constant terms (possibly time-dependent) added to both equations y_t = c_t + F_t\theta_t + v_t \theta_t = d_t + G_t\theta_{t-1} + w_t, in the way that S-PLUS Finmetrics does? Is there any straightforward way to transform the above to the default setup? Thanks, Tsvetan -------------------------------------------------------- NOTICE: If received in
2010 Sep 28
0
Time invariant coefficients in a time varying coefficients model using dlm package
Dear R-users, I am trying to estimate a state space model of the form (1) b_t = G * b_t-1 + w_t w_t ~ N(0,W) (2) y_t= A' * x_t + H' * b_t + v_t v_t ~ N(0,V) (Hamilton 1984: 372) In particular my estimation in state space form looks like (3) a3_t = 1 * a3_t-1 + w_t w_t ~ N(0,W) (4) g_t = (a1, a2) * (1, P_t)' + u_t * a3_t + v_t v_t ~ N(0,V) where g_t is the
2010 Oct 06
1
dlm package: how to specify state space model?
Dear r-users! I have another question regarding the dlm package and I would be very happy if someone could give me a hint! I am using the dlm package to get estimates for an endogenous rate of capacity utilization over time. The general form of a state space model is (1) b_t = G * b_t-1 + w_t w_t ~ N(0,W) (2) y_t= A' * x_t + H' * b_t + v_t v_t ~ N(0,V) (Hamilton 1984: 372) The
2012 Dec 16
1
nls for sum of exponentials
Hi there, I am trying to fit the following model with a sum of exponentials - y ~ Ae^(-md) + B e^(-nd) + c the model has 5 parameters A, b, m, n, c I am using nls to fit the data and I am using DEoptim package to pick the most optimal start values - fm4 <- function(x) x[1] + x[2]*exp(x[3] * -dist) + x[4]*exp(x[5] * -dist) fm5 <- function(x) sum((wcorr-fm4(x))^2) fm6 <- DEoptim(fm5,
2011 Jun 15
1
Print the summary of a model to file
Hi there, I am having a strange problem. I am running nls on some data. #data x <- -(1:100)/10 y <- 100 + 10 * (exp(-x / 2) Using nls I fit an exponential model to this data and get a great fit summary(fit) Formula: wcorr ~ (Y0 + a * exp(m1 * -dist/100)) Parameters: Estimate Std. Error t value Pr(>|t|) Y0 -0.0001821 0.0002886 -0.631 0.528 a 0.1669675 0.0015223
2013 Jan 03
2
simulation
Dear R users, suppose we have a random walk such as: v_t+1 = v_t + e_t+1 where e_t is a normal IID noise pocess with mean = m and standard deviation = sd and v_t is the fundamental value of a stock. Now suppose I want a trading strategy to be: x_t+1 = c(v_t – p_t) where c is a costant. I know, from the paper where this equations come from (Farmer and Joshi, The price dynamics of common
2008 Oct 08
1
Suspicious output from lme4-mcmcsamp
Hello, R community, I have been using the lmer and mcmcsamp functions in R with some difficulty. I do not believe this is my code or data, however, because my attempts to use the sample code and 'sleepstudy' data provided with the lme4 packaged (and used on several R-Wiki pages) do not return the same results as those indicated in the help pages. For instance: > sessionInfo() R
2005 Dec 14
1
Kalman Filter Forecast using 'SSPIR'
Dear R Users, I am new to state-space modeling. I am using SSPIR package for Kalman Filter. I have a data set containing one dependent variable and 7 independent variables with 250 data points. I want to use Kalman Filter for forecast the future values of the dependent variable using a multiple regression framework. I have used ssm function to produce the state space (SS)
2012 Sep 21
1
translating SAS proc mixed into R lme()
Dear R users, I need help with translating these SAS codes into R with lme()? I have a longitudinal data with repeated measures (measurements are equally spaced in time, subjects are measured several times a year). I need to allow slope and intercept vary. SAS codes are: proc mixed data = survey method=reml; class subject var1 var3 var2 time; model score = var2 score_base var4 var5 var3
1999 Oct 25
1
GARCH models available
tseries_0.3-0 at CRAN now contains the following new features: NelPlo Nelson-Plosser Macroeconomic Time Series garch Fit GARCH Models to Time Series get.hist.quote Download Historical Finance Data jarque.bera.test Jarque-Bera Test na.remove NA Handling Routines for Time Series garch contains a GARCH estimation routine together
1999 Oct 25
1
GARCH models available
tseries_0.3-0 at CRAN now contains the following new features: NelPlo Nelson-Plosser Macroeconomic Time Series garch Fit GARCH Models to Time Series get.hist.quote Download Historical Finance Data jarque.bera.test Jarque-Bera Test na.remove NA Handling Routines for Time Series garch contains a GARCH estimation routine together
2008 May 07
0
Help with Mixed effect modeling in R
Hi everyone, I want to fit the following mixed effect model Y_ij = b_0i + b_1i * (t_ij*grp_ij == 1) + b_2i * (t_ij*grp_ij == 2) + v_0i + v_1i*t_ij + e_ij with a different covariance matrix of random effects for each group. (Y is the response t is time grp is the group indicator b 's are fixed effects v 's are random effects) I know that this is possible in SAS
2003 Sep 05
4
Basic Dummy Variable Creation
Hi There, While looking through the mailing list archive, I did not come across a simple minded example regarding the creation of dummy variables. The Gauss language provides the command "y = dummydn(x,v,p)" for creating dummy variables. Here: x = Nx1 vector of data to be broken up into dummy variables. v = Kx1 vector specifying the K-1 breakpoints p = positive integer in the range
2008 Sep 10
2
arima and xreg
Dear R-help-archive.. I am trying to figure out how to make arima prediction when I have a process involving multivariate time series input, and one output time series (output is to be predicted) .. (thus strictly speaking its an ARMAX process). I know that the arima function of R was not designed to handle multivariate analysis (there is dse but it doesnt handle arma multivariate analysis, only
1999 Sep 20
0
Updated tseries package
Fritz just put the updated tseries package to CRAN. I mainly removed (and corrected) code such that tseries fits together with package ts. New code is White's and Teraesvirta's tests for neglected non-linearity (also for the regression case). From the INDEX file: NelPlo Nelson-Plosser Macroeconomic Time Series adf.test Augmented Dickey-Fuller Test amif
1999 Sep 20
0
Updated tseries package
Fritz just put the updated tseries package to CRAN. I mainly removed (and corrected) code such that tseries fits together with package ts. New code is White's and Teraesvirta's tests for neglected non-linearity (also for the regression case). From the INDEX file: NelPlo Nelson-Plosser Macroeconomic Time Series adf.test Augmented Dickey-Fuller Test amif
2013 May 09
0
ARMA(p,q) prediction with pre-determined coefficients
I have the following time series model for prediction purposes *Loss_t = b1* Loss_(t-1) + b2*GDP_t + b3*W_(t-1)* where W_t is the usual white noise variable. So this is similar to ARMA(1,1) except that it also contains an extra predictor, GDP at time t. I have only 20 observations on each variable except GDP for which I know till 100 values. And most importantly,I have also calculated
2008 Sep 10
0
FW: RE: arima and xreg
hi: you should probably send below to R-Sig-Finance because there are some econometrics people over there who could also possibly give you a good answer and may not see this email ? Also, there's package called mar ( I think that's the name ) that may do what you want ? Finally, I don't know how to do it but I think there are ways of converting a multivariate arima into the
2003 Jul 14
2
Subsetting a matrix
I'd welcome some comments or advice regarding the situation described below. The following illustrates what seems to me to be an inconsistency in the behaviour of matrix subsetting: > Z<-matrix(c(1.1,2.1,3.1,1.2,2.2,3.2,1.3,2.3,3.3),nrow=3) > Z [,1] [,2] [,3] [1,] 1.1 1.2 1.3 [2,] 2.1 2.2 2.3 [3,] 3.1 3.2 3.3 > dim(Z) [1] 3 3 >