View source: R/spq_summarise.R
spq_summarise | R Documentation |
Summarise each group of results to fewer results
spq_summarise(.query, ...)
spq_summarize(.query, ...)
.query |
a list with elements of the query |
... |
variables by which to arrange
(or SPARQL strings escaped with |
A query object
result = spq_init() %>%
spq_add("?item wdt:P361 wd:Q297853") %>%
spq_add("?item wdt:P1082 ?folkm_ngd") %>%
spq_add("?area wdt:P31 wd:Q1907114") %>%
spq_label(area) %>%
spq_add("?area wdt:P527 ?item") %>%
spq_group_by(area, area_label) %>%
spq_summarise(total_folkm = sum(folkm_ngd))
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.