R/account_tags.R
, R/mention_tags.R
, R/tags.R
tags.Rd
Fetches tag information, returned as a tibble, for the given account. This can be done for both account information, as well as mentions.
# S3 method for brandseyer2.account tags(x, ...) # S3 method for list tags(x, ...) # S3 method for data.frame tags(x, ..., ac = attr(x, "account"), na.rm = TRUE) tags(x, ...)
x | An object to find tag information for, such as an |
---|---|
... | Extra arguments passed to functions. |
ac | An optional account object from which to take tag information. |
na.rm | Whether to keep mentions that have no tags. |
A tibble of tag information. Includes the name, namespace, and description of the tags. Note that topics are stored in the 'topics' namespace.
brandseyer2.account
: Get tags from an account object.
list
: Create a table of tags for the list of given accounts.
data.frame
: Fetch tag information from a tibble of mention data.
account() to fetch account data.
topics() to see just a list of topics.
mentions() to query mention data.
Constance Neeser
# See what namespaces are in your account account("TEST01AA") %>% tags() %>% dplyr::select(namespace) %>% table()#> . #> tag topic topic_tree #> 2 3 1#> # A tibble: 3 x 8 #> id name namespace description deleted forClassificati… children is_parent #> <int> <chr> <chr> <chr> <lgl> <lgl> <list> <lgl> #> 1 10 Paren… topic Has childr… FALSE FALSE <int [2… TRUE #> 2 11 Child… topic I am a chi… FALSE FALSE <NULL> FALSE #> 3 12 Child… topic I am also … FALSE FALSE <NULL> FALSE#> # A tibble: 11 x 10 #> account id name namespace description deleted forClassificati… children #> <chr> <dbl> <chr> <chr> <chr> <lgl> <lgl> <list> #> 1 TEST01AA 1 tag1 tag NA FALSE FALSE <NULL> #> 2 TEST01AA 2 tag2 tag Deleted TRUE FALSE <NULL> #> 3 TEST01AA 10 Paren… topic Has childr… FALSE FALSE <int [2… #> 4 TEST01AA 11 Child… topic I am a chi… FALSE FALSE <NULL> #> 5 TEST01AA 12 Child… topic I am also … FALSE FALSE <NULL> #> 6 TEST01AA 1001 Tree … topic_tr… Topics com… FALSE FALSE <int [1… #> 7 TEST02AA 101 tag1 tag NA FALSE FALSE <NULL> #> 8 TEST02AA 102 tag2 tag Deleted TRUE FALSE <NULL> #> 9 TEST02AA 1010 Paren… topic Has childr… FALSE FALSE <dbl [2… #> 10 TEST02AA 1011 Child… topic I am a chi… FALSE FALSE <NULL> #> 11 TEST02AA 1012 Child… topic I am also … FALSE FALSE <NULL> #> # … with 2 more variables: is_parent <lgl>, ac <list># Finding the tags that mentions matched. account("TEST01AA") %>% mentions("published inthelast week") %>% tags()#> # A tibble: 1 x 9 #> id tag.id name namespace description deleted forClassification children #> <chr> <int> <chr> <chr> <chr> <lgl> <lgl> <list> #> 1 2-1 1 tag1 tag NA FALSE FALSE <NULL> #> # … with 1 more variable: is_parent <lgl>