I want to see the best-performing products sales in a table and not in a plot.
Ex. Products = 1 2 3 4 5 6 7 8 9 10
Sales = 50 40 90 100 120 110 110 120 150 150
If there are over 1000's of datasets and I want to pick the top 5 sales based on products. what would be the code?
Tried using if-else function but doesn't seem to be working.
Q.2 can you share some references to understand the ifelse R functions concept ?
thanks in advance