Exploring Covid Testing
exploring_covid_testing.Rmd
Loading in COVID test concepts
covid_concepts = c(
'6b9d6cc1-4290-4b10-b74f-5b62e474e321',
'e3acbc57-d15b-4df2-aa3b-8225fa1a980a',
'57463cc4-1c55-4fad-bf56-4a199434720c')
Loading in Data (ensure to point to the data directory)
data_set <- load_data_set('path/to/data')
#> Warning: It is very unusual to provide both `email` and `path` to `bq_auth()`.
#> They relate to two different auth methods.
#> The `path` argument is only for a service account token.
#> If you need to specify your own OAuth client, use `bq_auth_configure()`.
#> It is very unusual to provide both `email` and `path` to `bq_auth()`.
#> They relate to two different auth methods.
#> The `path` argument is only for a service account token.
#> If you need to specify your own OAuth client, use `bq_auth_configure()`.
#> It is very unusual to provide both `email` and `path` to `bq_auth()`.
#> They relate to two different auth methods.
#> The `path` argument is only for a service account token.
#> If you need to specify your own OAuth client, use `bq_auth_configure()`.
#> It is very unusual to provide both `email` and `path` to `bq_auth()`.
#> They relate to two different auth methods.
#> The `path` argument is only for a service account token.
#> If you need to specify your own OAuth client, use `bq_auth_configure()`.
#> It is very unusual to provide both `email` and `path` to `bq_auth()`.
#> They relate to two different auth methods.
#> The `path` argument is only for a service account token.
#> If you need to specify your own OAuth client, use `bq_auth_configure()`.
#> It is very unusual to provide both `email` and `path` to `bq_auth()`.
#> They relate to two different auth methods.
#> The `path` argument is only for a service account token.
#> If you need to specify your own OAuth client, use `bq_auth_configure()`.
#> Warning in as.integer.integer64(x): NAs produced by integer overflow
Plot lab tests using the Lab Result table
data_set$lab_result %>%
filter(measurement_concept_id %in% covid_concepts) %>%
ggplot(aes(x = collection_date, y = person_id)) +
geom_point(size = 2.5) +
xlim(as_datetime(ymd(20200101)), now()) +
xlab('Covid Test Collection Date') +
ylab('Person') +
theme_linedraw() +
theme(axis.text.y = element_blank(),
axis.ticks.y = element_blank())