similar to: Rolling Sample VAR

Displaying 20 results from an estimated 600 matches similar to: "Rolling Sample VAR"

2012 Aug 17
5
specific matrix element tranformation
Hi guys, I am trying to write a function that allows me to perform specific transformations to each element of a 2 by 2 matrix to generate a 3 by 3 matrix. Input into function-2 by 2 matrix Output from function -3 by 3 matrix For example: # a is my original 2 by 2 matrix #b is my new 3 by 3 matrix set.seed(2) a=matrix(rnorm(4),ncol=2) #let's say these are the transformations i wish to
2010 Nov 30
3
saving multiple panes to PNG
After searching multiple combinations of keywords over the past two days and downloading n R graphics tutorials, I have not been able to find anything online or in my R books about how to save multiple plot panes to PNG. Specifically, I am using the irf() function in the vars package to generate plots of Impulse Response Functions: > x.data <-
2007 Oct 13
2
a question on impulse responses
Dear R users, I am using the vars package to calculate the impulse response functions and the forecast error variance decomposition of a VAR model. Unfortunately I do not know whether these functions assume unit or one standard deviation shocks. I tried to look into the code of these functions, but in vain: neither irf, nor vars::irf, nor vars:::irf output the code of the functions. Does someone
2012 Jul 09
1
Using loops to create matrices where the variables is called with $
Hi there, I am trying to make a VECM model which does a loop to pull of long run impact coefficients. The problem is that to calculate these for a,b,c I use the irf() function and they are stored in irf$a, irf$b, irf$c. What I would really like is to be able to call irf$[variablename(x)] where I can loop through i:n for x and it will pull out the right variable. This is a bit of a waste of time
2007 Sep 12
1
vars package, impulse response functions ??
I am fitting a reduced form VAR model using VAR in the vars library. I have several endogenous variables, and two exogenous variables. I would like to explore the effects of a shock to one of the exogenous variables on one of the endogenous variables. Using irf in the vars library only calculates the irf for the endogenous variables, this is obviously by design, is there some theoretical
2009 Mar 07
4
multivariate integration and partial differentiation
Could somebody share some tips on implementing multivariate integration and partial differentiation in R? For example, for a trivariate joint distribution (cumulative density function) of F(x,y,z), how to differentiate with respect to x and get the bivariate distribution (probability density function) of f(y,z). Or integrate f(x,y,z) with respect to x to get bivariate distribution of (y,z). Your
2007 Oct 12
1
calculate impulse responses
Dear R users, I need perform structural analysis on a no intercept VAR model. Unfortunately the functions irf.VAR and dfev that come with the MSBVAR package only work with objects output by the reduced.form.var function, which seems to only evaluate VAR models with intercept. Is there a way to suppress the estimation of intercept term in reduced.form.var? Do I need to modify the code, and if I
2010 May 30
1
Calling fft from C
Hi I have made a R function 'convolve2' for convolution of two real valued vectors based on Rs 'convolve' with option type="open" - see below. (exp.length and irf.length are variables set in another part of the program) I wish to implement the function convolve2 in C and use it in a function used from R with .Call - e.g. I need to call fft in C. All I can find in the
2011 May 12
2
Exporting interactive 3D plots with axes and labels
Hi, I have a question about exporting interactive 3D plots. I use the following code to plot a contour of a trivariate normal distribution: library(mvtnorm) library(rgl) library(misc3d) n=25 x=seq(-3,3,length=n) X=cbind(rep(x,each=n**2),rep(rep(x,each=n),n),rep(x,n**2)) p=array(dmvnorm(X,sigma=diag(3)*0.5+0.5),c(n,n,n)) contour3d(p,x,x,x,level=mean(p)) lim=c(-3,3)
2010 Aug 14
1
Help with graphing impulse response functions
Dear colleagues/contributors, I'd be pleased if someone could provide insights on how to plot impulse response functions in a format that can easily be copied in a word document just as plotting time-series of variables. I had followed the outline suggested by Benhard Pfaff [see http://127.0.0.1:17693/library/vars/html/irf.html] but I am unable to get the impulse response functions in a
2015 Sep 29
2
Building clang in llvm-3.7 on Linux with RT support enabled
Hi All, I need to build clang/llvm from source on an Ubuntu Linux system, in order to build the gnustep Objective-C environment. I was able to build clang using cmake without a problem (following the instructions at clang.llvm.org/get_started.html), but when I tried to build gnustep, I found that clang failed to compile an autoconf-generated program. The compile error in the configure log was:
2007 Aug 09
0
Interpret impulse response functions from irf in MSBVAR library
Hello, I am wondering if anyone knows how to interpret the values returned by irf function in the MSBVAR library. Some of the literature I have read indicates that impulse responses in the dependent variables are often based on a 1 unit change in the independent variable, but other sources suggest that they are based on a a change of 1 standard deviation. Any ideas which irf uses to compute the
2013 Mar 30
0
Scoping issue with irf() from {vars}
Dear all: There seems to be a problem with scoping, for irf() in vars, when called within a function. Try the following: ----------------------- testfun <- function(lags){ data(Canada) var.2c <- VAR(Canada, p = lags, type = "const") print(var.2c) } testfun(lags=3) ## Everything OK. Now this: testfun2 <- function(lags){ data(Canada) var.2c <- VAR(Canada, p = lags, type =
2012 Aug 16
4
Column Extraction from matrix
Hi all, I have a 4 by 100 matrix. I wish to extract each column and make it into a 2 by 2 matrix. I also want to assign names for each 2X2 matrix. For example set.seed(2) a=matrix(rnorm(400),ncol=100) a1=matrix(a[,1],ncol=2) a2=matrix(a[,2],ncol=2) . . . a100=matrix(a[,100],ncol=2) Any simple ideas. Thanks. B -- View this message in context:
2007 Oct 12
0
irfs from a no intercept VAR
Dear R users, I need perform structural analysis on a no intercept VAR model. Unfortunately the functions irf.VAR and dfev that come with the MSBVAR package only work with objects output by the reduced.form.var function, which seems to only evaluate VAR models with intercept. Is there a way to suppress the estimation of intercept term in reduced.form.var? Do I need to modify the code, and if I
2009 Jul 07
1
Error in Rolling window of function - rollapply
Dear Colleagues, I have faced with the problem that function rollaply with rolling window for calculation of volatility doesn't give the all results of calculations. I have run the rolling window for calculation in Excel and obtained that the number of outputs for Excel is 36 and for R is 18. The total number of observations is 37. In the attachment you can find pdf of the Excel and Excel
2015 Sep 29
2
Building clang in llvm-3.7 on Linux with RT support enabled
Building the BlocksRuntime isn’t supported via CMake at the moment. It should be pretty straightforward to make it work, but it currently isn’t supported. -Chris > On Sep 29, 2015, at 9:45 AM, Alex Wang via llvm-dev <llvm-dev at lists.llvm.org> wrote: > > As far as I know the makefile in there isn't the makefile that gets executed during the cmake build -- cmake generates its
2018 May 22
0
DCC model simulation in R
Hi, I have used R rmgarch package to implement EGARCH ADCC model from which I can extract conditional covariance matrix. Now I would like to introduce positive and/or negative shocks to see the asymmetric response of covariance. I have come to know that impulse response function (IRF) or volatility IRF is not compatible for any asymmetric models, therefore, the only way to introduce shocks into
2011 Mar 04
2
apply.rolling() to a multi column timeSeries
Hello there, I am trying to compute the 3 months return momentum with the timeSeries x.ts, which is just a subset of simple returns from a much bigger series, > class(x.ts) [1] "timeSeries" attr(,"package") [1] "timeSeries" > dim(x.ts) [1] 20 3 > x.ts[1:8,] GMT MS.US AAPL.US CA.FP 1996-01-31 0.15159065 -0.133391894
2009 Nov 27
2
How to compute Rolling analysis of Standard Deviation using ZOO package?
Hello: I want to get a rolling estimation of the stdev of my data. Searching the document, I found the function "rollapply" in the zoo package. For example, my series is "c", and i want get a period of 10 days, so i write the command below: roll.sd = rollapply( c, 10, sd, na.pad = TRUE, align = 'right' ) but there is an error in it ,and the computing cannot be