tidy_results: Tidy REF results and filter by Unit of Assessment

Description Usage Arguments Details Value Note Examples

View source: R/filter.R

Description

This is a convenience function for filtering REF2014 results from a particular Unit of Assessment (UoA; i.e. subject area) by its numeric ID, by exact name or by a partial regular expression.

Usage

1
tidy_results(number = NULL, name = NULL, grep = NULL, ...)

Arguments

number

an integer from 1 to 36. See UoA for a key

name

a string. See UoA for possible names

grep

a regular expression representing (part of) a UoA name

...

arguments passed to grepl

Details

As well as filtering the rows of the results dataset, this function also selects only the most useful columns and renames the column to 'snake_case', which is slightly more convenient for programming.

Value

A tibble containing the following columns:

Note

This function does not check how many UoAs are selected. It could be zero, one or all of them.

Examples

1
2
3
4
# All of the following are equivalent:
tidy_results(18)
tidy_results(name = 'Economics & Econometrics')
tidy_results(grep = 'con')

Selbosh/ref2014 documentation built on Nov. 15, 2019, 4:27 a.m.