Skip to contents

statswalesr is a package for downloading datasets from StatsWales.

In August 2024 the Welsh Government ended the OData service which statswalesr used under the hood to retrieve and search for data - you can read more here. In response, I’ve decided to deprecate all functions except statswales_get_dataset() which will use the Welsh Government’s temporary workaround to get data.

A documentation site generated by pkgdown can be found at this link.

Installation

You can install the latest version of statswalesr from GitHub:

# install.packages("devtools")
devtools::install_github("jamie-ralph/statswalesr")

Please note: The current version of this package (0.2.0) on CRAN still relies on the old OData service and will not work.

Getting data from StatsWales

The code below extracts data about revenue outturn expenditure.

library(statswalesr)

df <- statswales_get_dataset("LGFS0023")

Hex sticker by Lew Furber.