Giter VIP home page Giter VIP logo

Comments (9)

nk027 avatar nk027 commented on August 11, 2024

This applies to:

  • density
  • plot (parameters, irfs and fcasts)
  • as.mcmc
  • prep_data
  • get_var_set

In general we have to differentiate:

  • parameters (mostly vars now)
  • dependents or impulses (vars_impulse or vars)
  • independents / lagged dependents / responses (vars_response)

Hyperparameters only appear on their own, but for irfs and parameters we want to make both available (e.g. plot all lags of variable 1).

Also we should really make the names in plots nicer (than dep1-ind-1). Done in 2ea173e.

from bvar.

nk027 avatar nk027 commented on August 11, 2024
  • Note that for parameters the variables seem to be switched (vars_response = 1 plots all explanatories for dependent 1). Fixed in 2ea173e.
  • Also note that we might want to implement something like this for the summary method.

from bvar.

nk027 avatar nk027 commented on August 11, 2024

This can probably be tackled by just adjusting prep_data() and changing / deprecating arguments.

from bvar.

nk027 avatar nk027 commented on August 11, 2024

Okay, so I am still not completely sure about the naming - atm I'm thinking of keeping the structure with response / impulse for IRFs and explicit subsetting of betas. But considering the vars argument in forecasts I want to allow users to pass both betas (dependents) and hyperparameters to the argument. As mentioned, this can probably be done in prep_data() exclusively.
This then means that concurrent plot() / as.mcmc() of hyperparameters and betas is possible.

Implementation-wise it's then probably easiest to switch from adding requested vectors (as in the beta-case atm) to prepping everything (as in the hyperpar-case) and then subset.

from bvar.

nk027 avatar nk027 commented on August 11, 2024

I think this was wrong:

Note that for parameters the variables seem to be switched (vars_response = 1 plots all explanatories for dependent 1). Fixed in 2ea173e.

from bvar.

nk027 avatar nk027 commented on August 11, 2024

So f3e639b fixes up a lot and includes some testing.

  • The order of the data and names returned by prep_data definitely seems to be correct now.
  • vars now works via grep -- default is all hyperparameters. Hyperpars and dependent variables are checked directly with grep, dependents may also be accessed via an integer (i.e. position), independents also work via grep but need to specify a certain lag (e.g. ".*lag2" or "UNR.*lag4"), in order to be able to distinguish them from the independents.
  • vars_impulse and vars_response are currently not functional and will need to be reimplemented and tested for compatibility (in density, plot (parameters, irfs and fcasts) and as.mcmc).

from bvar.

nk027 avatar nk027 commented on August 11, 2024

Looking good at the moment. I re-added vars_impulse and vars_response - they now overwrite whatever vars does. I tested the examples and a bit more and it seems to work. Only thing that has to change is the example and function using independent_index().
See 2bb8010.

from bvar.

nk027 avatar nk027 commented on August 11, 2024

So by 4a48780 this seems to be working nicely. Nothing about independent_index() needs to be changed, since e.g. vars_impulse now feeds through get_var_set(), meaning that one can either use grepping or positions (it's sufficiently smart about that).
The one update missing is the documentation.

from bvar.

nk027 avatar nk027 commented on August 11, 2024

So apart from the documentation this is done and look to be working nicely. (Note that I removed fixed = TRUE to allow full grep in most cases.)

from bvar.

Related Issues (20)

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.