1 # Usage: R --slave -f verify.R
3 if (file.exists("descriptors.csv")) {
4 cat("Verifying descriptors.csv. This may take a while.\n")
5 d <- read.csv("descriptors.csv", stringsAsFactors = FALSE)
6 cat(" ", length(na.omit(d$bridgestatsend)), "of", length(d$descriptor),
7 "descriptors contain bridge stats.\n")
9 cat("descriptors.csv does not exist\n")
12 if (file.exists("statuses.csv")) {
13 cat("Verifying statuses.csv. This may take a while.\n")
14 s <- read.csv("statuses.csv", stringsAsFactors = FALSE)
15 cat(" ", length(s[s$running == TRUE, "running"]), "of",
16 length(s$running), "bridges contained in the statuses have the",
19 cat("statuses.csv does not exist\n")
22 if (file.exists("relays.csv")) {
23 cat("Verifying relays.csv. This may take a while.\n")
24 r <- read.csv("relays.csv", stringsAsFactors = FALSE)
25 summary(as.POSIXct(r$consensus))
28 if (file.exists("assignments.csv")) {
29 cat("Verifying assignments.csv. This may take a while.\n")
30 r <- read.csv("assignments.csv", stringsAsFactors = FALSE)
31 summary(as.POSIXct(r$assignment))