Dear all,
I have been assigned to create a series of tables from a dataset using a PROC PRINT procedure. The tables are to be sorted by a variable CodCd (Cause of death). I have done this using a BY statement and a piece of the code I am using to do this is as follows:
TITLE1 "Blood Pressure Summaries by Race";
PROC PRINT DATA = HypAnl.Hypanalysis1;
BY CodCd;
ID SSN;
VAR WtLb BMI SBP;
RUN;
TITLE;
One of the resulting tables looks like this:
Blood Pressure Summaries by Race
Cause of Death Code=Heart Failure
SSN | SubjectWeight | BMI | Systolic BP |
418-15-3055 | 212 | 27.1 | 161 |
423-12-7794 | 164 | 24.1 | 155 |
424-92-9797 | 176 | 23.1 | 168 |
798-08-2998 | 143 | 23.2 | 155 |
986-08-2045 | 161 | 26.6 | 160 |
My question is if there is a procedure that can remove the sub-header "Cause of Death Code=Heart Failure" from the output table?
Thank you in advance.
Statement titlen ; clears all titles equal to or higher than n.
This reset also takes place if you set a title value such as: titlen 'Summary';
Look at the byline option.
If you remove that line totally, you don't know which data is in the table.
Because of where the title "Cause of Death Code = Heart Failure" is located, I would think that it is a secondary title which would have been created in a TITLE2 Statement somewhere earlier in your code. Try using TITLE1; and TITLE2; just before the section of code you provided to make sure that you are canceling all of the previously specified titles in your program!
For example:
TITLE1;
TITLE2;
TITLE1 ''Blood Pressure Summaries by Race";
...
TITLE;
Statement titlen ; clears all titles equal to or higher than n.
This reset also takes place if you set a title value such as: titlen 'Summary';
Available on demand!
Missed SAS Innovate Las Vegas? Watch all the action for free! View the keynotes, general sessions and 22 breakouts on demand.
Learn how use the CAT functions in SAS to join values from multiple variables into a single value.
Find more tutorials on the SAS Users YouTube channel.