Presentation is loading. Please wait.

Presentation is loading. Please wait.

1 Understanding and Using NAMCS and NHAMCS Data: A Hands-On Workshop Part II-Using Raw Data Files Donald Cherry.

Similar presentations


Presentation on theme: "1 Understanding and Using NAMCS and NHAMCS Data: A Hands-On Workshop Part II-Using Raw Data Files Donald Cherry."— Presentation transcript:

1 1 Understanding and Using NAMCS and NHAMCS Data: A Hands-On Workshop Part II-Using Raw Data Files Donald Cherry

2 2 Session Goals A the end of this session I would like you to: A the end of this session I would like you to:  Be able to successfully download data files and create a SAS dataset for analysis  Understand some of the limitations and advantages of using NAMCS/NHAMCS downloadable data  Perform simple analyses

3 3 Using raw data files File structure File structure Exercises using SUDAAN & SAS Proc Surveymeans Exercises using SUDAAN & SAS Proc Surveymeans  Downloading data & creating a SAS dataset  Simple frequencies with/without standard errors  Creating a new variable-Asthma  Visit rates-male/female  Total number of drug mentions  Antidepressant drug mentions  Time spent with physician Trend considerations Trend considerations Other issues--multiple years/settings Other issues--multiple years/settings Summary Summary

4 4 File Structure Download data and layout from website Download data and layout from websitehttp://www.cdc.gov/nchs/about/major/ahcd/ahcd1.htm Flat ASCII files for each setting and year Flat ASCII files for each setting and year NAMCS: 1973-2002 NHAMCS: 1992-2002

5 5 Structure organization Provider provider info practice info geographic info Visit patient & visit info treatment & outcome info medications Medication 1 Drug ingredient 1-5Therapeutic class 1-3 Medication 2Medication 6Medication 5Medication 4Medication 3

6 6 Double-click: My Computer\Local Disk C:\DUC_04 Double-click: My Computer\Local Disk C:\DUC_04 Double-click: SAS file: Exercises Double-click: SAS file: Exercises Hands-on Exercises

7 7 proc surveyfreq data=namtest1; tables sex*ager; strata cstratm; cluster cpsum; weight patwt2; run; SAS version 9.1 example

8 8

9 9 Visit estimates PhycodeSexPatwt(Patwt/Pop)*100Sexwt 14011100(100/800)*10012.5 15221300(300/800)*10037.5 1001150(50/800)*1006.25 5001120(120/800)*10015 71.25 Female population=800 New variableCalculation* *Note: Rate=est/pop=Σ patwt/pop=1/pop*Σ patwt.

10 10 Arrays PhycodePatcodeMed1Med2Med3Med4Med5Med6Total 143113290590000900009000090000900001 143129500502995900009000090000900002 143132674090000900009000090000900001 143149000090000900009000090000900000 143152122835465402959000090000900003 Note: 90000=No mention. Total drug mentions: 7

11 11 Some considerations: SUDAAN vs. SAS Proc SurveymeansSUDAAN PROC Surveymeans design variables=cstratm, cpsum (1-stage design) nest=cstratm, cpsum nest=cstratm, cpsum strata cstratm strata cstratm cluster cpsum cluster cpsum Sort by design variables Sort by design variables Sort not needed Sort not needed Weight data: Patwt2 Weight data: Patwt2 Subgroup=identify categorical variables Subgroup=identify categorical variables Class=identify categorical variables Class=identify categorical variables Tables=analysis variables Tables=analysis variables Var=analysis variables Var=analysis variables

12 12 Trend considerations Variables routinely rotate on and off survey Variables routinely rotate on and off survey Be careful about trending diagnosis prior to 1979 because of ICDA (based on ICD-8) Be careful about trending diagnosis prior to 1979 because of ICDA (based on ICD-8) Even after 1980- be careful about changes in Even after 1980- be careful about changes inICD-9-CM Number of medications varies over years Number of medications varies over years 1980-81 – 8 medications 1985, 1989-94 – 5 medications 1995-2002 – 6 medications 2003+8 – medications Diagnostic & therapeutic checkboxes vary Diagnostic & therapeutic checkboxes vary Use spreadsheet for significance of trends Use spreadsheet for significance of trends

13 13 Combining multiple years 2 year combinations are best for subpopulation analysis 2 year combinations are best for subpopulation analysis 3-4 year combinations for disease specific analysis 3-4 year combinations for disease specific analysis Keep adding years until you have at least 30 raw cases in important cells Keep adding years until you have at least 30 raw cases in important cells RSE improves incrementally with the number of years combined RSE improves incrementally with the number of years combined

14 14 RSE improves incrementally with the number of years combined RSE = SE/x RSE = SE/x RSE for percent of visits by persons less than 21 years of age with diabetes RSE for percent of visits by persons less than 21 years of age with diabetes 1999 RSE =.08/.18 =.44 (44%) 1999 RSE =.08/.18 =.44 (44%) 1998 & 1999 RSE =.06/.18 =.33 (33%) 1998 & 1999 RSE =.06/.18 =.33 (33%) 1998, 1999, & 2000 RSE =.05/.21 =.24 (24%) 1998, 1999, & 2000 RSE =.05/.21 =.24 (24%)

15 15 NAMCS, ED, and OPD can be combined in one or multiple years NAMCS, ED, and OPD can be combined in one or multiple years NAMCS & OPD variables virtually identical, many ED variables are same NAMCS & OPD variables virtually identical, many ED variables are same OPD and NAMCS should be combined to get estimates of ambulatory physician care especially for African-American, Medicaid or adolescent subpopulations OPD and NAMCS should be combined to get estimates of ambulatory physician care especially for African-American, Medicaid or adolescent subpopulations Only NAMCS has physician specialty Only NAMCS has physician specialty Combining multiple settings

16 16 2001* 3- & 4-Stage design variables 2003 2002 1-Stage design variables only 1-Stage design variables 3- & 4-Stage design variables Design Variables—Survey Years *Plan to re-release years with 1-stage design variables.

17 17 Code to create design variables: survey years 2001 & earlier CPSUM=PSUM; CSTRATM = STRATM; IF CPSUM IN(1, 2, 3, 4) THEN DO; CPSUM = PROVIDER +100000; CSTRATM = (STRATM*100000) +(1000*(MOD(YEAR,100))) + (SUBFILE*100) + PROSTRAT; END; ELSE CSTRATM = (STRATM*100000);

18 18 If nothing else, remember…The Public Use Data File Documentation is YOUR FRIEND! Each booklet includes: Each booklet includes:  A description of the survey  Record format  Marginal data (summaries)  Various definitions  Reason for Visit classification codes  Medication & generic names  Therapeutic classes

19 19 Where to get more information? www.cdc.gov/nchs/about/major/ahcd1.htm www.cdc.gov/nchs/about/major/ahcd1.htm www.cdc.gov/nchs/about/major/ahcd1.htm Call Ambulatory Care Statistics Branch at 301-458-4600 Call Ambulatory Care Statistics Branch at 301-458-4600


Download ppt "1 Understanding and Using NAMCS and NHAMCS Data: A Hands-On Workshop Part II-Using Raw Data Files Donald Cherry."

Similar presentations


Ads by Google