For example when looking at the 2 tables below, we know rowpctn/rowpctsum tend to show % breakdown for entire row using a + b + c +d as denominator.
Class 1 | Class 2 | ||||||
Column 1 | Column 2 | Class 1 row total | Column 3 | Column 4 | Class 2 row total | Grand row total | |
Row 1 | a | b | a + b | c | d | c + d | a + b + c +d |
Class 1 | Class 2 | ||||||
Column 1 | Column 2 | Class 1 row total | Column 3 | Column 4 | Class 2 row total | Grand row total | |
Row 1 | a / (a + b + c +d) | b / (a + b + c +d) | (a + b) / (a + b + c +d) | c / (a + b + c +d) | d / (a + b + c +d) | (c + d) / (a + b + c +d) | 100% |
But is there a way to tally up to 100% for each section like this table below?
Class 1 | Class 2 | |||||
Column 1 | Column 2 | Class 1 row total | Column 3 | Column 4 | Class 2 row total | |
Row 1 | a / (a + b) | b / (a + b) | 100% | c / (c + d) | d / (c + d) | 100% |
Thank you
Good news: We've extended SAS Hackathon registration until Sept. 12, so you still have time to be part of our biggest event yet – our five-year anniversary!
Learn the difference between classical and Bayesian statistical approaches and see a few PROC examples to perform Bayesian analysis in this video.
Find more tutorials on the SAS Users YouTube channel.
Ready to level-up your skills? Choose your own adventure.