similar to: Package dlm version 0.8-1

Displaying 20 results from an estimated 1000 matches similar to: "Package dlm version 0.8-1"

2014 Jan 08
0
Strange behaviour of `dlm` package
Dear R-help! I have encountered strange behaviour (that is, far-off filtering, smoothing and forecast distributions under certain conditions) in the `dlm` package by Giovanni Petris. Here is an example: I use the annual hotel bookings time series data, which I model using a second order polinomial DLM. First I perform the analysis with the data in logarithmic form and everything seems to be
2013 Feb 20
1
Tracking time-varying objects with the DLM package (dynamic linear models in R)
Hello all, I am working with the dlm package, specifcially doing a dlm multivariate Y linear regression using dlmModReg and dlmFilter and dlmSmooth... I have altereted the inputs into dlmModReg to make them time-varying using JFF, JW etc. How do I track the results of the time varying system matrices? For example what I am really interested in is JW - my system variance matrix for each time
2013 Mar 08
0
using dlmModPoly in library dlm
Hi Group, I'm trying to build a model to predict a product's sale price. I'm researching the dlm package. Looks like I should use dlmModPoly, dlmMLE, dlmFilter, dlmSmooth, and finally dlmForecast. I'm looking at the Nile River example and I have a few questions: 1. If I only want to predict future sale price based on observed sale price, I should use a univariate model,
2011 Nov 18
0
Kalman Filter with dlm
I have built a Kalman Filter model for flu forecasting as shown below. Y - Target Variable X1 - Predictor1 X2 - Predictor2 While forecasting into the future, I will NOT have data for all three variables. So, I am predicting X1 and X2 using two Kalman filters. The code is below x1.model <- dlmModSeas(52) + dlmModPoly(1, dV=5, dW=10) x2.model <- dlmModSeas(52) + dlmModPoly(1, dV=10,
2009 May 10
1
Help with kalman-filterd betas using the dlm package
Hi all R gurus out there, Im a kind of newbie to kalman-filters after some research I have found that the dlm package is the easiest to start with. So be patient if some of my questions are too basic. I would like to set up a beta estimation between an asset and a market index using a kalman-filter. Much littarture says it gives superior estimates compared to OLS estimates. So I would like to
2011 Jun 03
0
How to reconcile Kalman filter result (by package dlm) with linear regression?
  Hello All,   I am working with dlm for the purpose of estimating and forecasting with a Kalman filter model. I have succesfully set up the model and started generating results. Of course, I need to somehow be sure that the results make sense. Without any apparent target to compare with, my natural selection is the results by odinary least square. The idea being that if I choose a diffuse prior,
2012 Jan 23
0
problems with dlmBSample of the dlm package
Dear R users, I am trying to use the dlm package, and in particular the dlmBSample function. For some reason that I am not able to understand, this function does not work properly and the plot of the result does not make sense, while dlmFilter works perfectly. I think that my_mod is correct, because the output of my_dlmFilter$mod is fine. Where is my mistake or my misunderstanding? This is the
2009 Mar 11
1
Forecasting with dlm
Hi All, I have a problem trying to forecast using the dlm package, can anyone offer any advise? I setup my problem as follows, (following the manual as much as possible) data for example to run code CostUSD <- c(27.24031,32.97051, 38.72474, 22.78394, 28.58938, 49.85973, 42.93949, 35.92468) library(dlm) buildFun <- function(x) { dlmModPoly(1, dV = exp(x[1]), dW = exp(x[2])) } fit <-
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
2011 Jun 03
0
Package dlm generates unstable results?
  Hi, All,   This is the first time I seriously use this package. However, I am confused that the result is quite unstable. Maybe I wrote something wrong in the code? So could anybody give me some hint? Many thanks.   My test model is really simple. Y_t = X_t * a_t + noise(V),(no Intercept here) a_t = a_{t-1} + noise(W)   I first run the following code: (I shall provide data at the end of the
2005 Mar 22
1
Package vignette and build
Hello, I am writing a package called 'DLM' containing a vignette. The vignette contains a chunck with the function call 'library(DLM)'. This worked fine with 'R CMD check DLM', but when it comes to building the package with 'R CMD build DLM' I get the following error message: * creating vignettes ... ERROR Error: chunk 1 Error in library(DLM) : There is no
2009 Sep 11
3
State Space models in R
Hello everybody, I am writing a review paper about State Space models in R, and I would like to cover as many packages as I reasonably can. So far I am familiar with the following tools to deal with SS models: * StructTS, Kalman* (in stats) * packages dse[1-2] * package sspir * package dlm I would like to have some input from users who work with SS models: are there any other packages for SS
2007 Sep 21
2
getAnywhere
Hello, How can I see a function called "+.dlm"? > methods("+") [1] +.Date +.dlm* +.POSIXt Non-visible functions are asterisked > getAnywhere("+.dlm") Error in grep(pattern, x, ignore.case, extended, value, fixed, useBytes) : invalid regular expression '+\.dlm' Thanks in advance, Giovanni -- Giovanni Petris <GPetris at uark.edu>
2013 Mar 27
0
Setting up a model in package dlm()
Hello, I apologize for such a basic question, but I have been trying to do this in multiple packages without much success. I am trying to set up a state space model for Kalman filtering. I am using package dlm. The DLM is specified by: observation: y(t) = F(t)*theta(t) + v(t) state: theta(t) = G(t)*theta(t-1) + w(t) I have no problem setting up a simple example where F is constant. I am
2006 Nov 01
0
OT: data from Harvey's book
Goodmorning, and sorry for the off-topic question. Does anybody know if the data sets used in Harvey's book "Forecasting, structural time series models and the Kalman filter" are available online? Thanks in advance, Giovanni -- __________________________________________________ [ ] [ Giovanni Petris GPetris at
2018 Mar 26
0
"dlm" Package: Calculating State Confidence Intervals
To Whom It May Concern, I estimated a model with 6 states (3 time-varying Regression parameters and 3 quarterly seasonality trends). The model is saved in the object titled "mod." Following the example in the documentation and using the commands below, I am attempting to use the function "dlmSvd2var" to implement SVD and calculate the 90% confidence errors for each
2018 Mar 28
0
"dlm" Package: Calculating State Confidence Intervals
To Whom It May Concern, I estimated a model with 6 states (3 time-varying Regression parameters and 3 quarterly seasonality trends). The model is saved in the object titled "mod." Following the example in the documentation and using the commands below, I am attempting to use the function "dlmSvd2var" to implement SVD and calculate the 90% confidence errors for each
2010 Jun 23
0
dlm package and Log Likelihoods
Hello, For this project I have been tasked with emulating an old Dynamic Linear Modelling paper's results in the R programming language with the same data. The majority of the work (creating the model, filtering, smoothing, forecasting, etc.) has been done via the dlm package, and I have been successful in at least mimicking the old project's plot and coming within reasonable range on
2011 Jul 29
0
dlmSum(...) and non-constant state space models
Hello, I would be very grateful if somebody more knowledgeable then me could assist me in the following. I have two (three actually but for simplicity I will say two) models which I would like to fit jointly as a state space object. Here are the equations: (1) w = a1 + b1*(p) + e1 a1 = a1[t-1] + g1 g1 = g1[t-1] + e2 b1 = b1[t-1] + e3 (2) d = a2 + b2*(w) + e3 a2 = a2[t-1] + e4 b2 = b2[t-1] + e5
2013 Feb 17
1
Hyperparameters in ARIMA models with dlm package
Hi, i'm beginner in Bayesian methods, I'm reading the documentation about dlm package and kalman filters, I'm looking for a example of transformation of ARIMA in a state space equivalent to use the dlm package and calcualte the hyperparameters. Someone can help me about it?. If it's possible with a arima(1,0,1) example, or more complex model. While I have more examples best for me.