I don't think the data structure you have proposed will work unfortunately. The problem is that a bar chart only supports a single category as axis and therefore you will struggle to merge both.
Using a simple data step to create a test table - you currently have the following:
data students;
infile datalines dsd;
input student : $9. admit : ddmmyy8. discharge : ddmmyy8.;
format admit date9. discharge date9.;
datalines;
Student 1,01/01/17,01/03/17
Student 2,01/02/17,01/06/17
Student 3,01/03/17,.
Student 4,01/04/17,.
Student 5,01/05/17,.
Student 6,01/06/17,.
;
run;
Are you able to produce the following data structure instead? This transposed structure uses a single data column with separate counts for admit and discharges:
data students;
infile datalines dsd;
input student : $9. date : ddmmyy8. admit discharge;
format date date9.;
datalines;
Student 1,01/01/17,1,0
Student 1,01/03/17,0,1
Student 2,01/02/17,1,0
Student 2,01/06/17,0,1
Student 3,01/03/17,1,0
Student 4,01/04/17,1,0
Student 5,01/05/17,1,0
Student 6,01/06/17,1,0
;
run;
In VA - you should be able to assign the date column as category and add both measures.
Hope this helps. Falko
... View more