knitr::opts_chunk$set( collapse = TRUE, comment = "#>" )
devtools::install_github("ytingc/rCTA",build_vignettes = TRUE) library(rCTA)
This vignette covers how to use function get_alert()
and alertstat()
in the rCTA
package. They allow users to look up real-time and detailed information of alerts and get an overview of the current bus services.
Function get_alert()
allows to get detailed information about current alerts, which is helpful for schedule traveling. The following example shows how to get the alert information of bus number 8:
result <-get_alert(bus = 8) knitr::kable(head(result))
Function alertstat()
allows to obtain an overview of current alerts of all CTA buses through a summary table that provide the count of each type of alerts.
result <- alertstat() knitr::kable(head(result), col.names = c("Type", "Frequency"))
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.