Choose Language Hide Translation Bar
Highlighted

value ordering question

I have a question about the "value ordering" property of a column. Suppose we are using big class data set. The default ordering for age is {12,13,...17}. I manually changed it to {17, 16,...12}.

When I call the summary function, I find that if age is used as group variable, the ordering works fine. But if using "sex" as group variable and "age" as subgroup variable, the ordering for age goes back to the default one. Is there anyway to fix this?
3 REPLIES 3
Highlighted
chungwei
Staff

Re: value ordering question

That is a bug in summary, that the subgroup column ignores the ordering property saved in the column. If the order is important, you might want to switch the the role, make it the grouping column. Alternatively, you can use Tabulate.
Highlighted

Re: value ordering question

That's interesting. Thank you very much!
Highlighted

Re: value ordering question

Or you can use proc sql in SAS.

Mirko
Article Labels

    There are no labels assigned to this post.