Data:
d2
# A tibble: 5 x 2
Dist n
<chr> <int>
1 003 194
2 011 180
3 013 157
4 017 279
5 026 208
From the above data "d2" I want to order the values in descending order for column 'n'. Also want top 2 values.
When I am using
arrange(desc(d2$n))
It is showing error:
Error in UseMethod("arrange_") :
no applicable method for 'arrange_' applied to an object of class "c('integer', 'numeric')"
Can anyone help me?