ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Discussion (Misc queries) (https://www.excelbanter.com/excel-discussion-misc-queries/)
-   -   Sorting Multiple Row Fields Separately (https://www.excelbanter.com/excel-discussion-misc-queries/135259-sorting-multiple-row-fields-separately.html)

Westy

Sorting Multiple Row Fields Separately
 
I have a PT example below, Data and Name are Data Fields (?)
Game
Data Name 1 2 3
Rate Jim 20 25 30
Bob 10 15 12
Runs Jim 2 5 12
Bob 5 7 10
Wkts Jim 1 2 5
Bob 3 5 7

I want to sort each row field separatley by the average of the Game data.
Eg The Name colomn and its Game Data in Rate field, to be sorted decending
by avergae of Game data, The Name colomn and its Game Data in Runs, to be
sorted ascending by avergae of Game data and so on for the rest of the data
fields.
I am fine with sorting by an average etc but it seems when I try to sort
with the usual pivot table methods it wants to sorts all the Data Fields the
same. I would like to maintain the same layout of pivot and avoid creating
multiple pivots, pasting values or manual sorting
PS - Not sure if I have used the correct PT terminology with "Fields" etc
but hopefully you can understand from example.



David McRitchie

Sorting Multiple Row Fields Separately
 
You will need to use a macro to sort a selection range (or a coded range)
by columns, one row at a time, see
http://google.com/groups?threadm=%23...%40tkmsftngp03

If you have never installed a macro see
http://www.mvps.org/dmcritchie/excel/getstarted.htm

---
HTH,
David McRitchie, Microsoft MVP - Excel
My Excel Pages: http://www.mvps.org/dmcritchie/excel/excel.htm
Search Page: http://www.mvps.org/dmcritchie/excel/search.htm

"westy" wrote in message ...
I have a PT example below, Data and Name are Data Fields (?)
Game
Data Name 1 2 3
Rate Jim 20 25 30
Bob 10 15 12
Runs Jim 2 5 12
Bob 5 7 10
Wkts Jim 1 2 5
Bob 3 5 7

I want to sort each row field separatley by the average of the Game data.
Eg The Name colomn and its Game Data in Rate field, to be sorted decending
by avergae of Game data, The Name colomn and its Game Data in Runs, to be
sorted ascending by avergae of Game data and so on for the rest of the data
fields.
I am fine with sorting by an average etc but it seems when I try to sort
with the usual pivot table methods it wants to sorts all the Data Fields the
same. I would like to maintain the same layout of pivot and avoid creating
multiple pivots, pasting values or manual sorting
PS - Not sure if I have used the correct PT terminology with "Fields" etc
but hopefully you can understand from example.






All times are GMT +1. The time now is 10:28 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com