vignettes/covidHubUtils-zoltar_sqlite_setup.Rmd
covidHubUtils-zoltar_sqlite_setup.Rmd
We now support loading forecast from a local zoltar sqlite file in
covidHubUtils
. To use this functionality, you need to set
source = "local_zoltar"
and provide the
local_zoltpy_path
and zoltar_sqlite_file
parameters in load_forecasts()
.
Please follow these steps to set up the required environment prior to using this functionality for the first time:
Note: This feature is currently beta, so please contact us to create an sqlite file for you that contains the forecasts you want to work with.
--user
)
via:pip3 install pipenv
Set up your R environment so that the PATH
environment variable includes both the python3
and
pipenv
commands. You can read more about R and environment
variables here.
Clone the zoltpy
package from here.
In the cloned zoltpy
directory, run:
pipenv --three
pipenv shell
pipenv install
DBI
and RSQLite
in
Rstudiozoltar
sqlite file form here.covidHubUtils::load_forecasts()
with
your actual absolute or relative paths. For example:
covidHubUtils::load_forecasts(
models = "COVIDhub-ensemble",
locations = "US",
source = "local_zoltar",
local_zoltpy_path = "<your_zoltpy_dir>",
zoltar_sqlite_file = "<your_db.sqlite3_dir>")