fct_rev: Reverse order of factor levels

Description Usage Arguments Examples

View source: R/rev.R

Description

This is sometimes useful when plotting a factor.

Usage

1

Arguments

f

A factor (or character vector).

Examples

1
2
f <- factor(c("a", "b", "c"))
fct_rev(f)

tidyverse/forcats documentation built on Jan. 11, 2019, 11:10 a.m.