Hi there,
I need to create a table (se attached Excel file showing how the table should look at the en). I have data (se attached Excel fil representing the data source with the variables I need to analyse).
I think it should work with proc tabulate, but I am not sure how to use it. I the dataset the variable "Vikt" must be use according to the Freq statement.
I will be grateful for your help 🙂
Thanks
/MCB
Hi,
A lot of folks don't like to open Excel files. What code have you tried? How do you read your data? It is usually a good idea to post code in plain text format in the form of a DATA step so people can copy your program to make data or do a sample dataset using the SASHELP data, which everyone has. The code icon (little notebook with the running man icon) allows you to post code without having the Forum re-format the code.
Cynthia
How do we tell from your data which are people with deduction of tax for pension? In terms of the variables in your "data"
You have column heading like:
Deduction of Tax for pension savings | ||||
0-1,2 | 1,2-2,4 | 2,4-6,0 | 6,0-12,0 | 12,0- |
but there is not an obvious connection to the values of the "deduction" variable which are more in the 4500, 12000 or 17000 values. How do they map to that row of values?
You also show in your desired table:
Where by Category : |
1 |
2 |
3 |
What does that mean? Or that supposed to be the category variable is also used as a row header?
Instructions here: https://communities.sas.com/t5/SAS-Communities-Library/How-to-create-a-data-step-version-of-your-dat... will show how to turn an existing SAS data set into data step code that can be pasted into a forum code box using the {i} icon or attached as text to show exactly what you have and that we can test code against.
You might want to include labels so we know which variable may represent "people".
Are you ready for the spotlight? We're accepting content ideas for SAS Innovate 2025 to be held May 6-9 in Orlando, FL. The call is open until September 16. Read more here about why you should contribute and what is in it for you!
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.