Giter VIP home page Giter VIP logo

bayesvar_tvp's Introduction

bayesVAR_TVP

R/C++ implementation of Bayes VAR-TVP models.

Package can be installed using devtools, e.g.

library(devtools)
install_github("GediminasB/bayesVAR_TVP")

bayesvar_tvp's People

Contributors

gediminasb avatar lemuelemos avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar

bayesvar_tvp's Issues

data

how to include data (excel file) based on tvp-favar model?
exemple please

A problem in TVP VAR estimation

Bayes Var_tvp(mdata)
Error in solve.default(t(x.train) %*% x.train):
The system is computationally singular: reciprocal condition number = 2.54636e-17

Capture d'écran 2023-12-24 104446

any help please

hello, I try to install the package on Mac, and I failed. Did anyone succeed?

code:
library(devtools)
install_github("hadley/dplyr")
install_github("GediminasB/bayesVAR_TVP")

result:

library(devtools)
install_github("hadley/dplyr")
Skipping install of 'dplyr' from a github remote, the SHA1 (cfb3b714) has not changed since last install.
Use force = TRUE to force installation
install_github("GediminasB/bayesVAR_TVP")
Downloading GitHub repo GediminasB/bayesVAR_TVP@HEAD
✓ checking for file ‘/private/var/folders/y6/5fd4_3vd0dnfcyt69hl_y1600000gn/T/Rtmp9cEMkj/remotes2f84399ff35a/GediminasB-bayesVAR_TVP-2966e7c/DESCRIPTION’ ...
─ preparing ‘bayesVARTVP’:
✓ checking DESCRIPTION meta-information ...
─ cleaning src
Warning: /private/var/folders/y6/5fd4_3vd0dnfcyt69hl_y1600000gn/T/RtmpShwWfA/Rbuild43283ea555de/bayesVARTVP/man/bayesFAVAR_TVP.Rd:34: unknown macro '\Lambda'
─ installing the package to process help pages
-----------------------------------
─ installing source package ‘bayesVARTVP’ ...
** using staged installation
** libs
clang++ -mmacosx-version-min=10.13 -std=gnu++11 -I"/Library/Frameworks/R.framework/Resources/include" -DNDEBUG -I'/Library/Frameworks/R.framework/Versions/4.0/Resources/library/Rcpp/include' -I'/Library/Frameworks/R.framework/Versions/4.0/Resources/library/RcppArmadillo/include' -I/usr/local/include -fPIC -Wall -g -O2 -Wall -pedantic -fdiagnostics-color=always -c RcppExports.cpp -o RcppExports.o
In file included from RcppExports.cpp:4:
In file included from /Library/Frameworks/R.framework/Versions/4.0/Resources/library/RcppArmadillo/include/RcppArmadillo.h:34:
In file included from /Library/Frameworks/R.framework/Versions/4.0/Resources/library/Rcpp/include/Rcpp.h:57:
/Library/Frameworks/R.framework/Versions/4.0/Resources/library/Rcpp/include/Rcpp/DataFrame.h:136:18: warning: unused variable 'data' [-Wunused-variable]
SEXP data = Parent::get__();
^
1 warning generated.
clang++ -mmacosx-version-min=10.13 -std=gnu++11 -I"/Library/Frameworks/R.framework/Resources/include" -DNDEBUG -I'/Library/Frameworks/R.framework/Versions/4.0/Resources/library/Rcpp/include' -I'/Library/Frameworks/R.framework/Versions/4.0/Resources/library/RcppArmadillo/include' -I/usr/local/include -fPIC -Wall -g -O2 -Wall -pedantic -fdiagnostics-color=always -c rcppDrawBeta_CC.cpp -o rcppDrawBeta_CC.o
In file included from rcppDrawBeta_CC.cpp:3:
In file included from /Library/Frameworks/R.framework/Versions/4.0/Resources/library/RcppArmadillo/include/RcppArmadillo.h:34:
In file included from /Library/Frameworks/R.framework/Versions/4.0/Resources/library/Rcpp/include/Rcpp.h:57:
/Library/Frameworks/R.framework/Versions/4.0/Resources/library/Rcpp/include/Rcpp/DataFrame.h:136:18: warning: unused variable 'data' [-Wunused-variable]
SEXP data = Parent::get__();
^
1 warning generated.
clang++ -mmacosx-version-min=10.13 -std=gnu++11 -I"/Library/Frameworks/R.framework/Resources/include" -DNDEBUG -I'/Library/Frameworks/R.framework/Versions/4.0/Resources/library/Rcpp/include' -I'/Library/Frameworks/R.framework/Versions/4.0/Resources/library/RcppArmadillo/include' -I/usr/local/include -fPIC -Wall -g -O2 -Wall -pedantic -fdiagnostics-color=always -c rcppDrawBeta_DK.cpp -o rcppDrawBeta_DK.o
In file included from rcppDrawBeta_DK.cpp:3:
In file included from /Library/Frameworks/R.framework/Versions/4.0/Resources/library/RcppArmadillo/include/RcppArmadillo.h:34:
In file included from /Library/Frameworks/R.framework/Versions/4.0/Resources/library/Rcpp/include/Rcpp.h:57:
/Library/Frameworks/R.framework/Versions/4.0/Resources/library/Rcpp/include/Rcpp/DataFrame.h:136:18: warning: unused variable 'data' [-Wunused-variable]
SEXP data = Parent::get__();
^
1 warning generated.
clang++ -mmacosx-version-min=10.13 -std=gnu++11 -I"/Library/Frameworks/R.framework/Resources/include" -DNDEBUG -I'/Library/Frameworks/R.framework/Versions/4.0/Resources/library/Rcpp/include' -I'/Library/Frameworks/R.framework/Versions/4.0/Resources/library/RcppArmadillo/include' -I/usr/local/include -fPIC -Wall -g -O2 -Wall -pedantic -fdiagnostics-color=always -c rcppIRF.cpp -o rcppIRF.o
In file included from rcppIRF.cpp:3:
In file included from /Library/Frameworks/R.framework/Versions/4.0/Resources/library/RcppArmadillo/include/RcppArmadillo.h:34:
In file included from /Library/Frameworks/R.framework/Versions/4.0/Resources/library/Rcpp/include/Rcpp.h:57:
/Library/Frameworks/R.framework/Versions/4.0/Resources/library/Rcpp/include/Rcpp/DataFrame.h:136:18: warning: unused variable 'data' [-Wunused-variable]
SEXP data = Parent::get__();
^
1 warning generated.
clang++ -mmacosx-version-min=10.13 -std=gnu++11 -I"/Library/Frameworks/R.framework/Resources/include" -DNDEBUG -I'/Library/Frameworks/R.framework/Versions/4.0/Resources/library/Rcpp/include' -I'/Library/Frameworks/R.framework/Versions/4.0/Resources/library/RcppArmadillo/include' -I/usr/local/include -fPIC -Wall -g -O2 -Wall -pedantic -fdiagnostics-color=always -c rcppPredictiveSim.cpp -o rcppPredictiveSim.o
In file included from rcppPredictiveSim.cpp:3:
In file included from /Library/Frameworks/R.framework/Versions/4.0/Resources/library/RcppArmadillo/include/RcppArmadillo.h:34:
In file included from /Library/Frameworks/R.framework/Versions/4.0/Resources/library/Rcpp/include/Rcpp.h:57:
/Library/Frameworks/R.framework/Versions/4.0/Resources/library/Rcpp/include/Rcpp/DataFrame.h:136:18: warning: unused variable 'data' [-Wunused-variable]
SEXP data = Parent::get__();
^
1 warning generated.
clang++ -mmacosx-version-min=10.13 -std=gnu++11 -I"/Library/Frameworks/R.framework/Resources/include" -DNDEBUG -I'/Library/Frameworks/R.framework/Versions/4.0/Resources/library/Rcpp/include' -I'/Library/Frameworks/R.framework/Versions/4.0/Resources/library/RcppArmadillo/include' -I/usr/local/include -fPIC -Wall -g -O2 -Wall -pedantic -fdiagnostics-color=always -c rcppRmvnorm.cpp -o rcppRmvnorm.o
In file included from rcppRmvnorm.cpp:3:
In file included from /Library/Frameworks/R.framework/Versions/4.0/Resources/library/RcppArmadillo/include/RcppArmadillo.h:34:
In file included from /Library/Frameworks/R.framework/Versions/4.0/Resources/library/Rcpp/include/Rcpp.h:57:
/Library/Frameworks/R.framework/Versions/4.0/Resources/library/Rcpp/include/Rcpp/DataFrame.h:136:18: warning: unused variable 'data' [-Wunused-variable]
SEXP data = Parent::get__();
^
1 warning generated.
clang++ -mmacosx-version-min=10.13 -std=gnu++11 -I"/Library/Frameworks/R.framework/Resources/include" -DNDEBUG -I'/Library/Frameworks/R.framework/Versions/4.0/Resources/library/Rcpp/include' -I'/Library/Frameworks/R.framework/Versions/4.0/Resources/library/RcppArmadillo/include' -I/usr/local/include -fPIC -Wall -g -O2 -Wall -pedantic -fdiagnostics-color=always -c rcppbayesVAR.cpp -o rcppbayesVAR.o
In file included from rcppbayesVAR.cpp:3:
In file included from /Library/Frameworks/R.framework/Versions/4.0/Resources/library/RcppArmadillo/include/RcppArmadillo.h:34:
In file included from /Library/Frameworks/R.framework/Versions/4.0/Resources/library/Rcpp/include/Rcpp.h:57:
/Library/Frameworks/R.framework/Versions/4.0/Resources/library/Rcpp/include/Rcpp/DataFrame.h:136:18: warning: unused variable 'data' [-Wunused-variable]
SEXP data = Parent::get__();
^
1 warning generated.
clang++ -mmacosx-version-min=10.13 -std=gnu++11 -dynamiclib -Wl,-headerpad_max_install_names -undefined dynamic_lookup -single_module -multiply_defined suppress -L/Library/Frameworks/R.framework/Resources/lib -L/usr/local/lib -o bayesVARTVP.so RcppExports.o rcppDrawBeta_CC.o rcppDrawBeta_DK.o rcppIRF.o rcppPredictiveSim.o rcppRmvnorm.o rcppbayesVAR.o -L/Library/Frameworks/R.framework/Resources/lib -lRlapack -L/Library/Frameworks/R.framework/Resources/lib -lRblas -L/usr/local/gfortran/lib/gcc/x86_64-apple-darwin18/8.2.0 -L/usr/local/gfortran/lib -lgfortran -lquadmath -lm -F/Library/Frameworks/R.framework/.. -framework R -Wl,-framework -Wl,CoreFoundation
ld: warning: directory not found for option '-L/usr/local/gfortran/lib/gcc/x86_64-apple-darwin18/8.2.0'
ld: warning: directory not found for option '-L/usr/local/gfortran/lib'
ld: library not found for -lgfortran
clang: error: linker command failed with exit code 1 (use -v to see invocation)
make: *** [bayesVARTVP.so] Error 1
ERROR: compilation failed for package ‘bayesVARTVP’
─ removing ‘/private/var/folders/y6/5fd4_3vd0dnfcyt69hl_y1600000gn/T/RtmpShwWfA/Rinst432858a881f3/bayesVARTVP’
-----------------------------------
ERROR: package installation failed
錯誤: Failed to install 'bayesVARTVP' from GitHub:
System command 'R' failed, exit status: 1, stdout + stderr (last 10 lines):
E> clang++ -mmacosx-version-min=10.13 -std=gnu++11 -dynamiclib -Wl,-headerpad_max_install_names -undefined dynamic_lookup -single_module -multiply_defined suppress -L/Library/Frameworks/R.framework/Resources/lib -L/usr/local/lib -o bayesVARTVP.so RcppExports.o rcppDrawBeta_CC.o rcppDrawBeta_DK.o rcppIRF.o rcppPredictiveSim.o rcppRmvnorm.o rcppbayesVAR.o -L/Library/Frameworks/R.framework/Resources/lib -lRlapack -L/Library/Frameworks/R.framework/Resources/lib -lRblas -L/usr/local/gfortran/lib/gcc/x86_64-apple-darwin18/8.2.0 -L/usr/local/gfortran/lib -lgfortran -lquadmath -lm -F/Library/Frameworks/R.framework/.. -framework R -Wl,-framework -Wl,CoreFoundation
E> ld: warning: directory not found for option '-L/usr/local/gfortran/lib/gcc/x86_64-apple-darwin18/8.2.0'
E> ld: warning: directory not found for option '-L/usr/local/gfortran/lib'
E> ld: library not fou
library(bayesVAR_TVP)
Error in library(bayesVAR_TVP) :
there is no package called ‘bayesVAR_TVP’

If anyone can tell me how you download it, I will really appreciate!

install error

I couldn't install this package on both win7 and mac systems. It seems it has a problem. It is the error message:

Error: package or namespace load failed for 'bayesVARTVP' in library.dynam(lib, package, package.lib):
 DLL 'bayesVAR' not found: maybe not installed for this architecture?
Error: loading failed
Execution halted
*** arch - x64
Error: package or namespace load failed for 'bayesVARTVP' in library.dynam(lib, package, package.lib):
 DLL 'bayesVAR' not found: maybe not installed for this architecture?
Error: loading failed
Execution halted
ERROR: loading failed for 'i386', 'x64'
* removing 'C:/Users/Hamed/Documents/R/win-library/3.4/bayesVARTVP'
In R CMD INSTALL
Installation failed: Command failed (1)

error in function

i run the function beyesVAR_TVP with an error:
Error in index(y) : could not find function "index"

how to deal with it?? 3q~

package installation failed

I've been trying to install the bayesVAR_TVP package, but the package could not be installed, seems there is a problem with some files in the package, I always get these messages

 Warning in get_bibentries(package = package, ..., stop_on_error = FALSE) :
 Couldn't find file REFERENCES.bib in package `bayesVAR'
   Loading required namespace: bayesVAR
   Failed with error:  'there is no package called 'bayesVAR''
   Warning in get_bibentries(package = package, ..., stop_on_error = FALSE) :
 Couldn't find file REFERENCES.bib in package `bayesVAR'
   Loading required namespace: bayesVAR
   Failed with error:  'there is no package called 'bayesVAR''
   Warning in eval(expr, env) :
   Failed to insert reference with key = KoopKorobilis2010 from package = 'bayesVAR'. 
Possible cause --- missing REFERENCES.bib in package 'bayesVAR' or '

     Failed to insert reference with key = KoopKorobilis2010 from package = 'bayesVAR'. 
Possible cause --- missing REFERENCES.bib in package 'bayesVAR' or 'bayesVAR' not installed.
   Warning in eval(expr, env) :
     Failed to insert reference with key = CC1994 from package = 'bayesVAR'. Possible cause --- 
missing REFERENCES.bib in package 'bayesVAR' or 'bayesVAR' not installed.
   Warning in eval(expr, env) :
     Failed to insert reference with key = DK2002 from package = 'bayesVAR'. Possible cause --- 
missing REFERENCES.bib in package 'bayesVAR' or 'bayesVAR' not installed.
   Warning in eval(expr, env) :
     Failed to insert reference with key = CogleySargent2005 from package = 'bayesVAR'. 
Possible cause --- missing REFERENCES.bib in package 'bayesVAR' or 'bayesVAR' not installed.
   *** installing help indices
     converting help for package 'bayesVARTVP'
       finding HTML links ... done
       MinimumEntropy_weights                  html  
       bayesFAVAR_TVP                          html  
       bayesVAR_TVP                            html  
       impulse.response                        html  
       plot.beta                               html  
       predictive.density                      html  
   ** building package indices
   ** testing if installed package can be loaded
   Error: package or namespace load failed for 'bayesVARTVP' in library.dynam(lib, package, package.lib):
DLL 'bayesVAR' not found: maybe not installed for this architecture?
   Error: loading failed
   Execution halted
   ERROR: loading failed
-  removing 
'C:/Users/BOUBEK~1/AppData/Local/Temp/RtmpYdejQ6/Rinst18d413135e92/bayesVARTVP'
   In R CMD INSTALL
         -----------------------------------


   ERROR: package installation failed

Error: Failed to install 'bayesVARTVP' from GitHub:
  System command error

can`t compile /src C++ code

my frend,
your package can not be build by Rstudio ,Windows systyem.

==> Rcpp::compileAttributes()

  • Updated R/RcppExports.R

==> Rcmd.exe INSTALL --no-multiarch --with-keep.source bayesVARTVP

  • installing to library 'D:/Softwares/R-4.0.2/library'

  • installing source package 'bayesVARTVP' ...
    ** using staged installation
    ** libs
    make: Nothing to be done for 'all'.
    installing to D:/Softwares/R-4.0.2/library/00LOCK-bayesVARTVP/00new/bayesVARTVP/libs/x64
    ** R
    ** inst
    ** byte-compile and prepare package for lazy loading
    ** help
    Warning in get_bibentries(package = package, ..., stop_on_error = FALSE) :
    Couldn't find file REFERENCES.bib in package bayesVAR' Loading required namespace: bayesVAR Failed with error: 'there is no package called 'bayesVAR'' Warning in eval(expr, env) : Failed to insert reference with key = Robertson2005 from package = 'bayesVAR'. Possible cause --- missing REFERENCES.bib in package 'bayesVAR' or 'bayesVAR' not installed. Warning: E:/BuildPackages/bayesVARTVP/man/bayesFAVAR_TVP.Rd:42: unknown macro '\Lambda' Warning in get_bibentries(package = package, ..., stop_on_error = FALSE) : Couldn't find file REFERENCES.bib in package bayesVAR'
    Loading required namespace: bayesVAR
    Failed with error: 'there is no package called 'bayesVAR''
    Warning in get_bibentries(package = package, ..., stop_on_error = FALSE) :
    Couldn't find file REFERENCES.bib in package bayesVAR' Loading required namespace: bayesVAR Failed with error: 'there is no package called 'bayesVAR'' Warning in get_bibentries(package = package, ..., stop_on_error = FALSE) : Couldn't find file REFERENCES.bib in package bayesVAR'
    Loading required namespace: bayesVAR
    Failed with error: 'there is no package called 'bayesVAR''
    Warning in get_bibentries(package = package, ..., stop_on_error = FALSE) :
    Couldn't find file REFERENCES.bib in package bayesVAR' Loading required namespace: bayesVAR Failed with error: 'there is no package called 'bayesVAR'' Warning in eval(expr, env) : Failed to insert reference with key = KoopKorobilis2010 from package = 'bayesVAR'. Possible cause --- missing REFERENCES.bib in package 'bayesVAR' or 'bayesVAR' not installed. Warning in eval(expr, env) : Failed to insert reference with key = CC1994 from package = 'bayesVAR'. Possible cause --- missing REFERENCES.bib in package 'bayesVAR' or 'bayesVAR' not installed. Warning in eval(expr, env) : Failed to insert reference with key = DK2002 from package = 'bayesVAR'. Possible cause --- missing REFERENCES.bib in package 'bayesVAR' or 'bayesVAR' not installed. Warning in eval(expr, env) : Failed to insert reference with key = Bernanke2004 from package = 'bayesVAR'. Possible cause --- missing REFERENCES.bib in package 'bayesVAR' or 'bayesVAR' not installed. Warning in get_bibentries(package = package, ..., stop_on_error = FALSE) : Couldn't find file REFERENCES.bib in package bayesVAR'
    Loading required namespace: bayesVAR
    Failed with error: 'there is no package called 'bayesVAR''
    Warning in get_bibentries(package = package, ..., stop_on_error = FALSE) :
    Couldn't find file REFERENCES.bib in package bayesVAR' Loading required namespace: bayesVAR Failed with error: 'there is no package called 'bayesVAR'' Warning in get_bibentries(package = package, ..., stop_on_error = FALSE) : Couldn't find file REFERENCES.bib in package bayesVAR'
    Loading required namespace: bayesVAR
    Failed with error: 'there is no package called 'bayesVAR''
    Warning in get_bibentries(package = package, ..., stop_on_error = FALSE) :
    Couldn't find file REFERENCES.bib in package `bayesVAR'
    Loading required namespace: bayesVAR
    Failed with error: 'there is no package called 'bayesVAR''
    Warning in eval(expr, env) :
    Failed to insert reference with key = KoopKorobilis2010 from package = 'bayesVAR'. Possible cause --- missing REFERENCES.bib in package 'bayesVAR' or 'bayesVAR' not installed.
    Warning in eval(expr, env) :
    Failed to insert reference with key = CC1994 from package = 'bayesVAR'. Possible cause --- missing REFERENCES.bib in package 'bayesVAR' or 'bayesVAR' not installed.
    Warning in eval(expr, env) :
    Failed to insert reference with key = DK2002 from package = 'bayesVAR'. Possible cause --- missing REFERENCES.bib in package 'bayesVAR' or 'bayesVAR' not installed.
    Warning in eval(expr, env) :
    Failed to insert reference with key = CogleySargent2005 from package = 'bayesVAR'. Possible cause --- missing REFERENCES.bib in package 'bayesVAR' or 'bayesVAR' not installed.
    *** installing help indices
    converting help for package 'bayesVARTVP'
    MinimumEntropy_weights html
    bayesFAVAR_TVP html finding HTML links ... ����

    bayesVAR_TVP html
    impulse.response html
    plot.beta html
    predictive.density html
    ** building package indices
    ** testing if installed package can be loaded from temporary location
    Error: package or namespace load failed for 'bayesVARTVP' in library.dynam(lib, package, package.lib):
    DLL 'bayesVAR' not found: maybe not installed for this architecture?
    ����: ����ʧ��
    ִֹͣ��
    ERROR: loading failed

  • removing 'D:/Softwares/R-4.0.2/library/bayesVARTVP'

Exited with status 1.

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.