tests/test.reorder.factor.R

## Test results before and after loading gdata

m <- factor(c("a", "b", "c"))

(m1 <- reorder(m, X=c(3, 2, 1)))

library(gdata)

(m2 <- reorder(m, X=c(3, 2, 1)))

stopifnot(identical(m1, m2))

Try the gdata package in your browser

Any scripts or data that you put into this service are public.

gdata documentation built on Oct. 17, 2023, 1:11 a.m.