I'm trying to use a custom sort on a bar chart, but for some reason the sort only works if i add another variable as a group.
I've set up the custom sort like this:
When i use it in a bar chart i get:
However if i add another variable as a group it sorts properly:
What am I missing?
In "report designer", on your graph, you need to tell it how to sort.
I haven't tried this in 7.4, but this has caused frustration for me in 7.3, so my guess is, it's the same you need to do.
What I do, is press the name of the variable on the graph, select sort and then select ascending/descending.
In your case, you should click on the name "Alder 10-årsklasser" just below you barchart, then a menu should pop up allowing you to select sort -> ascending/descending. It should sort using the custom sort you have made.
In "report designer", on your graph, you need to tell it how to sort.
I haven't tried this in 7.4, but this has caused frustration for me in 7.3, so my guess is, it's the same you need to do.
What I do, is press the name of the variable on the graph, select sort and then select ascending/descending.
In your case, you should click on the name "Alder 10-årsklasser" just below you barchart, then a menu should pop up allowing you to select sort -> ascending/descending. It should sort using the custom sort you have made.
Don’t miss the livestream kicking off May 7. It’s free. It’s easy. And it’s the best seat in the house.
Join us virtually with our complimentary SAS Innovate Digital Pass. Watch live or on-demand in multiple languages, with translations available to help you get the most out of every session.
See how to use one filter for multiple data sources by mapping your data from SAS’ Alexandria McCall.
Find more tutorials on the SAS Users YouTube channel.