srlanalytics / bdfm

Bayesian dynamic factor model estimation and predictive statistics including nowcasting and forecasting
MIT License
5 stars 6 forks source link

Testing #44

Closed christophsax closed 5 years ago

christophsax commented 5 years ago

In RStudio, you can press Ctrl-Shift-T to run the integrated tests. Right now, the following mini example fails, but we would have spotted it with the test

  library(bdfm)
  fdeaths0 <- fdeaths
  fdeaths0[length(fdeaths0)] <- NA
  dta <- cbind(fdeaths0, mdeaths)

  m <- dfm(dta)
#> Error in PrinComp(Y[, long], m): Not a matrix.

Created on 2019-02-21 by the reprex package (v0.2.1)

You can also adjust tests and add new ones in tests/testthat.

srlanalytics commented 5 years ago

This issue has been resolved and I've reinstated a few other tests too. I'll keep adding tests as we go, but things are running better now!