Skip to contents

Opens a minimal Shiny dashboard for inspecting attempts, registered questions, gradebook rows, and CSV exports.

Usage

run_dashboard(
  db_path,
  tutorial_id = NULL,
  rule = c("last", "best", "first"),
  include_unregistered = TRUE,
  group_id = NULL,
  host = "127.0.0.1",
  access_token = NULL,
  token_envvar = "LEARNRTRACKR_DASHBOARD_TOKEN",
  allow_remote = FALSE,
  ...
)

Arguments

db_path

Path to an existing SQLite tracking database.

tutorial_id

Optional tutorial identifier selected at startup. If NULL, the first available tutorial is selected.

rule

Scoring rule passed to gradebook().

include_unregistered

If TRUE, include attempted questions that were not registered with register_questions().

group_id

Optional registered student group identifier selected at startup. If supplied, the dashboard is filtered to students in that group.

host

Host passed to shiny::runApp(). Defaults to "127.0.0.1" for local-only use.

access_token

Optional dashboard token. If supplied, the dashboard asks for this token before showing data.

token_envvar

Environment variable used to read a dashboard token when access_token is NULL. Set to NULL to disable environment lookup.

allow_remote

If FALSE, refuse to run on a non-local host unless an access token is configured.

...

Additional arguments passed to shiny::runApp().

Value

The return value of shiny::runApp().

Examples

if (FALSE) { # \dontrun{
db_path <- "learnrtrackr.sqlite"
run_dashboard(db_path)
} # }