fct_discard {tern}R Documentation

Discard specified levels of a factor

Description

[Stable]

This discards the observations as well as the levels specified from a factor.

Usage

fct_discard(x, discard)

Arguments

x

(factor)
the original factor.

discard

(character)
levels to discard.

Value

A modified factor with observations as well as levels from discard dropped.

Examples

fct_discard(factor(c("a", "b", "c")), "c")


[Package tern version 0.9.5 Index]