powered by
Drop unused factor levels in a data frame.
dropunusedlevels(x)
the data frame
# NOT RUN { iris[1:10,]$Species dropunusedlevels(iris[1:10,])$Species # }
Run the code above in your browser using DataLab