Which of the following sort a dataframe by the order of the elements in B?
(a) x[rev(order(x$B)),]
(b) x[ordersort(x$B),]
(c) x[order(x$B),]
(d) x[rev(x$B),]
The question was posed to me in a job interview.
Question is from Commands topic in section Commands, Packages, Visualizing Data and Linear Regression of R Programming