Learn R Programming

examly (version 0.2.0)

norm_letter: Normalize letter grades

Description

Cleans and validates a vector of characters, keeping only standard letter grades (A, B, C, D, E).

Usage

norm_letter(x)

Value

A character vector of normalized grades (A-E) or NA.

Arguments

x

A vector, typically character.

Examples

Run this code
norm_letter(c(" a ", "B", "c", "F", "d", NA))

Run the code above in your browser using DataLab