View Single Post
  #1   Report Post  
Posted to microsoft.public.excel.worksheet.functions
Iriemon Iriemon is offline
external usenet poster
 
Posts: 89
Default sort and select based on criteria

I have a spreadsheet with the following data, what I would like to do is:

1. sort this in descending order by number of sales (got the macro doing this)
2. Determine the total sales ( a simple SUM in an adjacent cell. (done)
3. Calculate what 90% of total sales are. ( done in another adjacent cell)
4. Determine which parts make up the 90% of sales. (HELP)
5. Graph only the 90% parts. Graph is already created but how do I capture
the 90% dataset. (HELP)

The idea is to take the entire dataset, sort by number of sales and then
graph only those parts that make up 90% of the sales.

Part number sales
part1 8
part2 5
part3 84
part4 10
part5 4
part6 59
part7 105
part8 9
part9 3
part10 8
part11 1
part12 134
part13 148
part14 3
part15 33
part16 8

With the above data, it should "grab"

part13 148
part12 134
part7 105
part3 84
part6 59
part15 33


Any ideas are greatly appreciated.

Irie