We have a data as follows
date state sales
ddmmyyyy a 10
ddmmyyyy b 20
ddmmyyyy c 30
ddmmyyyy d 40
ddmmyyyy e 50
ddmmyyyy a 10
ddmmyyyy b 5
ddmmyyyy c 11
ddmmyyyy d 14
ddmmyyyy e 18
Now how to convert the date so that i can plot a bars chart(grouped bars) for comparision of sales for each quarter(i.e. of previous and current year quarter) with state as category using SAS Report Designer v7.3.
Instructions on how to work with dates as SAS dates in SAS Visual Analytics can be found in Bobbie Wagoner's very good blog post
Making Best Use of Date Formats in Visual Analytics Designer
If you select a quarter SAS date format you should be able to achieve the bar chart your after.
Please let us know how you go and mark the question as answered if it is.
I've done as given in the blog, but the data is coming as sum of 2 year in single bar, where as both should be shown in different bars.
Category used is the Continent. If I use date then its showing differently.
Any work around for this?
it it is difficult to understand and visualise what you are wanting and what you are getting. Are you able to provide screenshots to describe the scenario better?
Sorry Balraj - it isn't clear from sample data screenshot what you want in your visualization. Perhaps you can draw what you want and explain what you mean by "area". For the community to assist, we need to have a clearer understanding of your requirements.
From what I understand you may need to also duplicate your Transaction Date column so that you have 2 date columns. One of them use a format for year and the other date column use a format for quarter. This way you can use the quarter column for grouping.
Registration is open! SAS is returning to Vegas for an AI and analytics experience like no other! Whether you're an executive, manager, end user or SAS partner, SAS Innovate is designed for everyone on your team. Register for just $495 by 12/31/2023.
If you are interested in speaking, there is still time to submit a session idea. More details are posted on the website.
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.