Online File
Rick Aster: Professional SAS Programming Shortcuts: Contents
proc report data=work.volcano nowd spacing=3 headline; column name ('- Location -' latitude latx longitude longx) ('Elevation' elevation elevationft); define name / 'Volcano' order width=22 left spacing=5; define latitude / noprint display format=8.2; define latx / 'Latitude' computed width=9 right; define longitude / noprint display format=9.2; define longx / 'Longitude' computed width=9 right spacing=2; define elevation / '(meters)' mean format=comma8.; define elevationft / '(feet)' computed format=comma8. spacing=0; compute latx / character length=9; if latitude > .z then do; latx = put(abs(latitude), f6.2); if latitude > 0 then substr(latx, 8) = 'N.'; else if latitude < 0 then substr(latx, 8) = 'S.'; end; endcomp; compute longx / character length=9; if longitude > .z then do; longx = put(abs(longitude), f6.2); if longitude > 0 then substr(longx, 8) = 'E.'; else if longitude < 0 then substr(longx, 8) = 'W.'; end; endcomp; compute elevationft; elevationft = elevation.mean/.3048; endcomp; rbreak after / summarize ol; run;