View source: R/dw_data_from_chart.R
dw_data_from_chart | R Documentation |
maturing
Downloads the data from an existing Datawrapper chart, that ypu have access to. This is the mirrored function to dw_data_to_chart
.
dw_data_from_chart(chart_id, api_key = "environment")
chart_id |
Required. A Datawrapper-chart-id as character string, usually a five character combination of digits and letters, e.g. "aBcDe". Or a dw_chart-object. You need to have access to the chart (e.g. it was created by yourself or in one of your teams). |
api_key |
Optional. A Datawrapper-API-key as character string. Defaults to "environment" - tries to automatically retrieve the key that's stored in the .Reviron-file by |
A data.frame.
This function downloads a R-dataframe from a Datawrapper chart.
Benedict Witzenberger
## Not run: dw_data_from_chart(df, "aBcDE") # uses the preset key in the .Renviron-file
## Not run: df <- dw_data_from_chart(df, chart_id = "a1B2Cd", api_key = "1234ABCD") # uses the specified key
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.