Learn R Programming

⚠️There's a newer version (1.0.2) of this package.Take me there.

zoltr - An R client for the Zoltar data repository API

Overview

This package contains functions for working with the Zoltar forecast repository's API, including projects, models, forecasts, and scores. Read more at the zoltr pkgdown site.

Installation

You can install the released version of zoltr from CRAN with:

install.packages("zoltr")

And the development version from GitHub with:

# install.packages("devtools")
devtools::install_github("reichlab/zoltr")

Usage

Read more at the zoltr pkgdown site, but briefly you use the new_connection() function to create a connection to Zoltar and then pass that connection along with the ID of the resource of interest (e.g., a project, model, or forecast) to this package's various functions like projects(), project_info(), or scores().

library(zoltr)
conn <- new_connection()
conn
#> ZoltarConnection 'https://zoltardata.com' not authenticated

the_projects <- projects(conn)
project_id <- the_projects[1,]$id
the_project_info <- project_info(conn, project_id)
names(the_project_info)
#>  [1] "id"           "url"          "owner"        "is_public"   
#>  [5] "name"         "description"  "home_url"     "core_data"   
#>  [9] "config_dict"  "template"     "truth"        "model_owners"
#> [13] "score_data"   "models"       "locations"    "targets"     
#> [17] "timezeros"
the_project_info$name
#> [1] "CDC Flu challenge"

Copy Link

Version

Install

install.packages('zoltr')

Monthly Downloads

318

Version

0.2.2

License

GPL-3

Issues

Pull Requests

Stars

Forks

Maintainer

Matthew Cornell

Last Published

May 30th, 2019

Functions in zoltr (0.2.2)

delete_forecast

Delete a forecast
forecast_info

Gets a forecast's information
forecasts

Get a model's forecasts
forecast_data

Gets a forecast's data
project_info

Get information about a project
new_connection

Get a connection to a Zoltar host
model_info

Get information about a model
upload_forecast

Upload a forecast
models

Get a project's models
zoltar_authenticate

Log in to a Zoltar host
zoltr-package

zoltr: Interface to the 'Zoltar' Forecast Repository API
upload_info

Get an upload's information
projects

Get information about all projects
scores

Get a project's scores