Giter Club home page Giter Club logo

tvargirf's Issues

tvarGIRF with external variable threshold in TVAR

I want to estimate a TVAR with a threshold external to the model.
I cannot get the state-dependent GIRFs and the relative confidence interval. Specifically, I would like to get confidence bound from the empirical distribution of simulated GIRFs, assuming normality.

I run the below code:

data(zeroyld)
x=rnorm(482)
xx=as.vector(x)
xx=as.vector(x,mode="any")
t5<-TVAR(zeroyld, lag=3, nthresh=1, thDelay=1, thVar=xx, gamma=0.248, trim=0.1, mTh=2, plot=FALSE)
library(tvarGIRF)

c1=GIRF(t5, c(0,1),restrict.to=1)

I get an error: c1=GIRF(t5, c(0,1),restrict.to=1)
Error: Simulations of models with external transition variables (argument thVar in TVAR) not supported

So i detach the package tvarGIRF and I calculate the GIRF with GIRF {tsDyn}.
detach("package:tvarGIRF", unload = TRUE)

c2<-GIRF(t5)
A<-plot(c2,
plot_type = c( "line"),
n.ahead = c(1, 5, 10),
var = unique(c2$var)[1],
n_simu = c(50))

This command works but I can not obtain the state-dependent GIRF and the relative confidence intervals.

Thank you in advance,
Antonino

some bugs of GIRF

Hi~Moore,I have a bug when I run the following code related to GIRF:

code.txt
data1.xlsx

the bugs demostrate that "Error in if (round(z2[i - thDelay], round_digits) <= Thresh[1]) { :
missing value where TRUE/FALSE needed"

And I have tied to figure out the problem but ended up with failure.
Could you please give me some help ? Thanks for your kind consideration.

what is the meaning of the red color and underline?

Hi~Moore.Thank you for your related work on GIRF of TVAR. I have some question about the result. And I would appreciate it if you could reply.
After I run the following code
library(tsDyn)
library(tvarGIRF)
data(zeroyld)
exampleTVAR <- TVAR(zeroyld, lag=2, nthresh=1, thDelay=1, mTh=1, plot=FALSE)
girf_full <- GIRF(exampleTVAR4, c(0,1), horizon =10, H = 10, R = 50,restrict.to =NA )
girf_full[["responses"]]

the results show:

short.run long.run

1 -0.00493 0.996
2 0.0380 0.954
3 0.0105 0.888
4 0.0381 0.849
5 0.0828 0.831
6 0.110 0.799
7 0.126 0.795
8 0.105 0.729
9 0.131 0.671
10 0.142 0.643

The color of number " -0.00493" is red. And there are some underlines in the last number of "-0.00493"、“0.0380”、“0.0380”、“0.0380”、“0.0828”. What is the meaning of the red color and these underlines? Does these indicate the negtive number and redundant fractional parts ?

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.