Skip directly to search Skip directly to A to Z list Skip directly to navigation Skip directly to site content Skip directly to page options
CDC Home

NHANES Dietary Web Tutorial

Download Data Files

Purpose

Throughout, this tutorial uses examples related to calcium and milk to illustrate the principles and instructions presented in the modules.  We have created three full programs for these examples, entitled “Milk,” “Food Sources,” and “Supplement.” These programs encompass all the steps involved in preparing an analytic dataset and conducting the various analyses covered in this tutorial.  There are is an additional fourth program, entitled “Outliers,” that is used as an example in Module 9.  These full programs can be found in the Additional Resources section of the tutorial.  However, starting with this module and continuing through the end of the course, shorter snippets of code can be found in most of the “How To” sections to illustrate the topic being discussed.

In order to create and use these programs, you need to first download data files. NHANES dietary data files are available for download from the website as SAS transport files (.XPT).  The SAS transport format allows data files to be extracted on Windows-, UNIX-, or Macintosh-based systems (this tutorial focuses only on Windows-based systems).  To use these transport files, you need to create folders in which to save them, download the data files and documentation, and then extract and save NHANES data files in a SAS-accessible library.

 

Info iconIMPORTANT NOTE

Although SAS is not required for mastering the content of this tutorial, it does need to be installed if you plan to download and use the data files on your own computer to run the example code provided.

 

Task 1: Create Folders

You will create folders to save your data files, documentation, and extracted SAS datasets. This folder structure will help keep your transport files and datasets organized.

 

Task 2: Download Data Files and Documentation

You will need to download the NHANES data transport files to create your analytic dataset, and you will need the documentation for reference as you conduct your analysis.

 

Task 3: Extract and Save NHANES Data Files in a SAS-Accessible Library

After downloading the SAS transport files, you will need to extract the data and save them as SAS datasets in a SAS-accessible library.  A library is a folder that you designate on your computer to store your SAS files. Transport files are not usable without completing this task.

 

Contact Us:
  • National Center for Health Statistics
    3311 Toledo Rd
    Hyattsville, MD 20782
  • 1 (800) 232-4636
  • cdcinfo@cdc.gov
USA.gov: The U.S. Government's Official Web PortalDepartment of Health and Human Services
Centers for Disease Control and Prevention   1600 Clifton Road Atlanta, GA 30329-4027, USA
800-CDC-INFO (800-232-4636) TTY: (888) 232-6348 - Contact CDC–INFO
A-Z Index
  1. A
  2. B
  3. C
  4. D
  5. E
  6. F
  7. G
  8. H
  9. I
  10. J
  11. K
  12. L
  13. M
  14. N
  15. O
  16. P
  17. Q
  18. R
  19. S
  20. T
  21. U
  22. V
  23. W
  24. X
  25. Y
  26. Z
  27. #