powered by
Order the documents in a corpus by variables, including document variables.
# S3 method for corpus arrange(.data, ...)
A corpus with documents reordered according to the specified variables.
a corpus object whose documents will be sorted
comma-separated list of unquoted document variables, or expressions involving document variables. Use desc to sort a variable in descending order.
arrange(data_corpus_inaugural[1:5], President) arrange(data_corpus_inaugural[1:5], c(3, 2, 1, 5, 4)) arrange(data_corpus_inaugural[1:5], desc(President))
Run the code above in your browser using DataLab