slide1 n.
Download
Skip this Video
Loading SlideShow in 5 Seconds..
Getting Superscripts into your SAS output Martha Cox Population Health Research Unit Community Health & Epidemiology PowerPoint Presentation
Download Presentation
Getting Superscripts into your SAS output Martha Cox Population Health Research Unit Community Health & Epidemiology

Loading in 2 Seconds...

play fullscreen
1 / 14

Getting Superscripts into your SAS output Martha Cox Population Health Research Unit Community Health & Epidemiology - PowerPoint PPT Presentation


  • 194 Views
  • Uploaded on

Getting Superscripts into your SAS output Martha Cox Population Health Research Unit Community Health & Epidemiology Dalhousie University. Two Methods. For PUT statements, labels, and formatted values, use hex values For ODS output, use in-line formatting with the ESCAPECHAR= option.

loader
I am the owner, or an agent authorized to act on behalf of the owner, of the copyrighted work described.
capcha
Download Presentation

Getting Superscripts into your SAS output Martha Cox Population Health Research Unit Community Health & Epidemiology


An Image/Link below is provided (as is) to download presentation

Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author.While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server.


- - - - - - - - - - - - - - - - - - - - - - - - - - E N D - - - - - - - - - - - - - - - - - - - - - - - - - -
Presentation Transcript
slide1
Getting Superscripts into your SAS outputMartha CoxPopulation Health Research UnitCommunity Health & EpidemiologyDalhousie University
two methods
Two Methods
  • For PUT statements, labels, and formatted values, use hex values
  • For ODS output, use in-line formatting with the ESCAPECHAR= option
the input data set report
Obs line count pct

1 LINE01 . .

2 LINE02 237228 .

3 LINE03 7425 .

4 LINE04 . .

5 LINE05 2706 36.4444

6 LINE06 390 5.2525

7 LINE07 94 1.2660

8 LINE08 4406 .

9 LINE09 . .

10 LINE10 3 0.0681

11 LINE11 23 0.5220

The input data set: REPORT
using hex values in put statements
Using Hex Values in PUT Statements

data _null_;

file print;

put 'This is a superscript zero''b0'x;

put 'This is a superscript one''b9'x;

put 'This is a superscript two''b2'x;

put 'This is a superscript three''b3'x;

run;

- - - - - - - - - - - - - - - - - - - - - - - - - -

This is a superscript zero°

This is a superscript one¹

This is a superscript two²

This is a superscript three³

using hex values in labels
Using Hex Values in Labels

proc print data=sashelp.class label;

label age=age'b2'x;

run;

- - - - - - - - - - - - - - - - - - - - - - - - - -

Obs Name Sex age² Height Weight

1 Alfred M 14 69.0 112.5

2 Alice F 13 56.5 84.0

3 Barbara F 13 65.3 98.0

4 Carol F 14 62.8 102.5

5 Henry M 14 63.5 102.5

using hex values in format values
Using Hex Values in Format Values

proc format;

value $line

'LINE01' = 'Inclusion Criteria'

'LINE02' = 'Men and women 18-24 years of age on 01-APR-02 and

eligible for Nova Scotia Medicare'

'LINE03' = "who were first diagnosed with rhythmopathy during the

period 01-APR-02 to 31-MAR-03" 'b9'x

'LINE04' = 'Exclusion Criteria'

'LINE05' = 'Those with a previous diagnosis of Boogie Fever in

the 5 years prior to index diagnosis'

'LINE06' = 'Those with a previous diagnosis of Boogie Woogie Flu

in the 5 years prior to index diagnosis'

'LINE07' = 'Those with a previous diagnosis of Rockin Pneumonia

in the 2 years prior to index diagnosis'

'LINE08' = 'Final Cohort'

'LINE09' = 'Outcomes'

'LINE10' = 'Clapping on the up-beat'

'LINE11' = "Chronic stepping on dance partner's feet"

;

run;

ods in line formatting
ODS In-line Formatting
  • Introduced as experimental for RTF and HTML in v8.2. Will be production for all destinations in v9.2.
  • Not found in on-line documentation.
  • Info found on SAS Support web site:
    • http://support.sas.com/rnd/base/topics/expv8/inline82.html
    • http://support.sas.com/rnd/base/topics/templateFAQ/Template_rtf.html#escapechar
ods in line formatting1
ODS In-line Formatting

ods rtf file="temp";

ods escapechar='^';

proc print data=sashelp.class;

title1 "This value is superscripted ^{super 2}";

title2 "This value is subscripted ^{sub 2}";

run;

- - - - - - - - - - - - - - - - - - - - - - - - - - - - -

ods in line formatting2
ODS In-line Formatting

ods rtf file="Rhythmopathy.rtf";

ods escapechar='^';

title1 j=l "Serious Complications of Rhythmopathy in Nova Scotia";

footnote1 "^S={font_face=Times font_size=9 pt}^{super 1} The first diagnosis of rhythmopathy received during the period 01-APR-02 to 31-MAR-03 is referred to throughout this document as the index colonoscopy.";

footnote2 "^S={font_face=Times font_size=9 pt}^{super 2} For exclusion criteria, N and % represent the number and percentage of patients in the initial cohort who satisfied that criterium.";

footnote3 "^S={font_face=Times font_size=9 pt} For outcomes, N and % represent the number and percentage of patients in the final cohort who satisfied the definition of that outcome.";

ods in line formatting3
ODS In-line Formatting

proc report data=prtlines2 headline nocenter;

column line count pct ;

define line / order order=data flow

left width=44 format=$line. ' ' ;

define count / display right width=8 format=comma8.

"N^{super 2}" ;

define pct / display right width=8 format=pct.

"(%)^{super 2}" ;

break after line / skip;

run;

ods rtf close;