1 / 12

Proc Forms

Proc Forms. An Example: Print selected variables To verify against original document Karol Katz,M.S. XXX Trial (Initial form) PLEASE VERIFY variables listed below (per Dr. G) MARK ANY ERRORS & CORRECT IN RED INK, (sign bottom right), return to BCU

clinton
Download Presentation

Proc Forms

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. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. Proc Forms An Example: Print selected variables To verify against original document Karol Katz,M.S.

  2. XXX Trial (Initial form) PLEASE VERIFY variables listed below (per Dr. G) MARK ANY ERRORS & CORRECT IN RED INK, (sign bottom right), return to BCU 8:57 Wednesday, June 16, 2004 -------- STUDY #=22043 Initials=IGRL -------- page 1 ..... Dt. of Birth....... 01/30/1946 page 1 ..... Gender............. 1 page 3 ..... Alcohol Use........ 2 page 7 ..... Syst/Diastolic BP.. 128 / 70 page 7 ..... Heart rate......... 72 page 12 .... Dt. randomized..... 12/01/1995 page 12 .... Dose mg/Day ........ 20.00 Date Verified ___/___/___ by___________ XXX Trial INITIAL EVALUATION ID…………………………….__ __ __ __(1-4) Patient's Initials:..................[] ( 6- 9) Study Center:...................................[] ( 10 ) [1: New Haven] [2: Boston] [3: Barcelona] [4: London] Date of Evaluation:......[//] (11-16) MM DD YR Date of Birth:......... .....[//] (17-22) MM DD YR Gender… [0: Female] [1: Male]…..[] ( 23 ) ~~~~~~continue for 11 pages~~~~~~~ Number of Bottles Dispensed…… …[] ( 63 ) Tablet Strength [1: 5 mg] [2: 10mg] .[] ( 64) Dose of study drug prescribed (mg/DAY).........[ . ] (65-69) REC# 7 (80)

  3. The FORMS Procedure • Mailing labels, file cards and any other printer forms that have a regular pattern • For each observation in the dataset a rectangular block ‘form unit’ is printed • Multiple copies can be requested • Size and spacing are controlled by options

  4. Proc Forms Options

  5. LINE Statement • Line line-number variable list</option list> • No need to specify statement for blank line • Options : INDENT – margin WITHIN ‘form unit’ LASTNAME – Rotates the word after a comma in character variable if found. Variable is Name Rotate and print Smith, James P. James P. Smith PACK removes extra blanks REMOVE delete a line if all values are blank

  6. Get variable labels from proc contents to use as text values on form. Patient Study Number Pt initials Gender Etiology of cirrhosis Alcohol use Systolic bp, mmHg Diastolic bp, mmHg (+more) 25 variables to be verified Set titles, set form options for form width , # forms on a page & total # lines Create a temporary dataset keeping the fields to be included on the form. Add variables for page #’s Add variables for “text” values. Create string variables (series of dots) for aligning values on form Plan Form Layout

  7. SAS program for forms data fake; set inh.fake; /*set page numbers*/ pdob=1;ppopgrp=1;pcetiol=1;palcuse=3; pbp=7; phr=7;ppems=7; ppeasc=7; palt=8; pbt=8; palb=8; pcreat=9; pptinr=9 ; panhcv=9; pcps=9 ; puspv=11; pwhvp=11; pfhvp=11; phvpg=11; pdtrand=12; ptrt=12; ptrtfreq=12;

  8. SAS program Continued label id='STUDY # ' ptin='Initials ' ; format dob dtrand mmddyy10.; where='page'; a='.....'; * separator for pages 1-9; b='....'; * separator for pages 10-12; slash='/'; verify= ' Date Verified ___/___/___ by___________';

  9. SAS program Continued(2) Ldob= 'Dt. of Birth.......'; Lpop= 'Population grp.....'; Leti= 'Etiology cirr......'; Lalc= 'Alcohol Use........'; LBP = 'Syst/Diastolic BP..'; ~~~~~~~~~ LDTRAND = 'Dt. randomized.....'; LTRT ='Dose mg/Day..'; LTRTFREQ='Frequency code..';

  10. SAS program Continued(3) options ps=51 ls=86; * sasmonospace 9; title1 'XXX Trial (Initial form) PLEASE VERIFY variables listed below (per Dr. G)'; title2 'MARK ANY ERRORS & CORRECT IN RED INK, (sign bottom right), return to BCU'; proc forms data=fake w=76 lines= 43 down=0 across=1 indent=2 ndown=1 ; by id ptin;

  11. SAS program Continued(4) line 1 where pdob a ldob dob/p; line 3 where ppopgrp a lpop popgrp/p; line 5 where pcetiol a leti cetiol/p; line 7 where palcuse a lalc alcuse/p; line 9 where pbp a lbp sbp slash dbp /p; ~~~~~~~~~~~~~~~~ line 41 where ptrt b ltrt trt a ltrtfreq trtfreq/p; line 43 verify; run;

  12. Sample form XXX Trial (Initial form) PLEASE VERIFY variables listed below (per Dr. G) MARK ANY ERRORS & CORRECT IN RED INK, (sign bottom right), return to BCU 13:57 Wednesday, June 16, 2004 ------------------------ STUDY #=52043 Initials=IGRL -------------   page 1 ..... Dt. of Birth....... 01/30/1946 page 1 ..... Gender............. 1   page 1 ..... Population grp..... 1   page 1 ..... Etiology cirr...... 1   page 3 ..... Alcohol Use........ 2   page 7 ..... Syst/Diastolic BP.. 128 / 70 ~~~~Form continues page 12 .... Dose mg/Day.. 20.00 .. Frequency code.. 4   Date Verified ___/___/___ by__________

More Related