proc-report(style)

整理文档很辛苦,赏杯茶钱您下走!

免费阅读已结束,点击下载阅读编辑剩下 ...

阅读已结束,您可以下载文档离线阅读编辑

资源描述

1“Table1”inScientificManuscripts;UsingPROCREPORTandtheODSSystemCarterSevick,DoDCenterforDeploymentHealthResearch,SanDiego,CAABSTRACTTheabilitytocombinethepowerandflexibilityofPROCREPORTandtheOutputDeliverySystem(ODS)hasrevolutionizedsummaryreportingandtablecreation.However,themajorityofresourcesavailableapproachthesubjectpredominantlyfromabusinessperspective.Researchersinpublichealthtendtoemphasizecategoricaldataovercontinuousandhaveadifferentaestheticwhenitcomestooveralllookanddesigncreatingtheneedforasubtlydifferentskillsetandapproach.ThispaperwilltakethereaderthroughtheprocessofcreatingasummarytablefromrawdataandpresentingtheresultsinRTFformat.Summarizeddatawillincludeabinaryexposurestratifiedbydemographicinformation,andinadditiontofrequencies,univariateanalyseswillalsobepresented.Itshouldbeemphasizedthatthispaperisnotadiscussionofastudy,butratheradiscussionofdatapresentation.ItwillbeassumedthatthereaderhasbeginningorintermediateexperiencewithSAS®.INTRODUCTIONFormanydataanalyststheproductionofsummarytablesisatimeconsumingprocessthatisoftenaccomplishedbyexportingSASprocedureresultstosomethirdpartywordprocessingorspreadsheetsoftwarewheretheactualbuildingofthetabletakesplace.Thisisamanualprocessthatwillneedtoberepeatedinitsentiretyiftheaudience(suchasaclientorsupervisor)desiresachangeinthecontent.Partofthebeautyofprogrammingisthatcodemaybereused,whilemouseclicksmaynot,andifthecreationofasummarytableisdoneviaprogrammingthensmalltweakingofcodemaybeallthatisnecessarytosatisfydemandsforchanges.ThispaperwilltakethereaderthroughtheprocessofcreatingasummarytablefromrawdataandpresentingtheresultsinRTFformat.THEDATAForthistutorialadatasetwasgeneratedtosimulatewhatananalystinthefieldofpublichealthmightencounter.Thecodeforthisdatasetisincludedintheappendix.Belowisapartiallistingofthesedata.Figure1.AlookatthedataObsgenderregionexposure11302020312040105010611170108030901010110Eachrowdescribesanindividualbirth.Thethreevariablescomposingthedatasetinclude:thechild’sgender,theregionofbirth,andabinaryexposurevariable.Theformatsthatdescribethelevelsofthesevariablesareincludedintheappendix.THEGOALFromthesedatawewouldliketoproduceatypeoftabletypicallyseeninthebeginningofscientificmanuscripts.“Table1”,asweliketocallit,providestheaudiencewithsummarydescriptionsofvariablestobestudiedinananalysis.“Table1’s”varyfromstudytostudymostlydependingonvariabletype,analysesusedandpersonalpreferences.But,theoverallmessageofthetableisconsistentlythesame.Thegoalofthispaperwillbetoproduceatablethatsummarizesthecountsoftotalbirthsandexposedbirthsstratifiedbygenderandregion.AdditionallywewouldliketodisplaytheresultsofaChi-squaretestforassociationbetweenexposurestatusandour2twocharacteristics.Table1(below)showstheendresultthatwewillbestrivingfor.Thistableshallbeproduced,asanRTFdocument,completelythroughprogrammingwithoutcuttingandpasting,orothersuchmanualword-processingactivities.Table1:CharacteristicsofSubjectsVariableAllbirthsn(n=2,000)Numberexposedn(%)(n=420)p-value1GenderofinfantFemale1,002204(20.4)0.4809Male998216(21.6)RegionofbirthMid-Lands1,090214(19.6)0.0036High-Lands45381(17.9)Low-Lands21558(27.0)Other-lands14342(29.4)Unknown9925(25.3)1Chi-squaretestforassociationTHEPATHTheprocessthatwewillfollowwillcomeintwosteps.Instepone,asummarydatasetwillbecreatedthatcontainsalloftheinformationthatneedstobedisplayed.SteptwoconsistsofemployingPROCREPORTandtheOutputDeliverySystem(ODS)tocreatethestructureofthetableandexportitintoanRTFdocument.Thesubjectmatterofsteponewillbetreatedinbriefwithonlythemoreunusualaspectsoftheprogramfullyexplained.SUMMARIZINGTHEDATAHowyougoaboutcreatingasummarydatasetisyourbusiness,buthoweveryoudoitaimtoendupwithvariablesthatmirrorthecolumnsthatyouwanttodisplayinyourtable.Uponinspection,Table1(above)canbebrokendownintothefollowingfivecolumnsofinformation:•Column1:Thiscolumnstateswhichvariableisbeingsummarizedinthecurrentrow.•Column2:Indicateswhichlevelofthevariableisbeingsummarizedinthecurrentrow.•Column3:Countsofbirthswhichfallintoeachlevelofeachvariable.•Column4:Acountofexposedbirthsineachlevelfollowedbythepercentageofbirthswithinthatlevel.•Column5:TheresultsofaChi-squaretestforassociationbetweenexposureandthevariablesummarizedinthatrow.Thefollowingprogramwillcreateadatasetcontainingfivevariablesdescribingthesefivecolumns.ForthefirststepPROCMEANSwillbecalledupontocreatethebasicsummarytobuildon.procmeansdata=DemoDatanoprintnsummean;classgenderregion;varexposure;ways1;outputout=PreTablen=sum=mean=/autoname;run;TheCLASSstatementinPROCMEANSiswhereyouplaceyourclassvariablesoverwhichyouwanttostratifyyouranalysisvariable.WhenmorethanonevariableisspecifiedintheCLASSstatementthestratificationoftheanalysisvariablewillbemadeoverallpossiblecrossingsoftheclassvariables.ThisbehaviorcanbemodifiedusingtheWAYSstatement.ThisstatementtellsPROCMEANShowmanyclassvariablestocombinetostratifyyouranalysisvariable.Sinceweonlywantoneclassvariableatatimea“1”isspecified.3Figure2displaystheresultfromtheabovecode.Figure2.ResultsfromPROCMEANSObsgenderregio

1 / 19
下载文档,编辑使用

©2015-2020 m.777doc.com 三七文档.

备案号:鲁ICP备2024069028号-1 客服联系 QQ:2149211541

×
保存成功