Skip to main content

Manipulating Data

  • Chapter
  • First Online:
SAS for Epidemiologists
  • 5427 Accesses

Abstract

In this chapter we spend some time discussing how to use DATA step to create new SAS variables, files out of old SAS variables, files with SET statements, as well as different ways to combine and merge data sets.

This is a preview of subscription content, log in via an institution to check access.

Access this chapter

eBook
USD 16.99
Price excludes VAT (USA)
  • Available as EPUB and PDF
  • Read on any device
  • Instant download
  • Own it forever
Softcover Book
USD 99.99
Price excludes VAT (USA)
  • Compact, lightweight edition
  • Dispatched in 3 to 5 business days
  • Free shipping worldwide - see info
Hardcover Book
USD 129.99
Price excludes VAT (USA)
  • Durable hardcover edition
  • Dispatched in 3 to 5 business days
  • Free shipping worldwide - see info

Tax calculation will be finalised at checkout

Purchases are for personal use only

Institutional subscriptions

Notes

  1. 1.

    In this case, the argument oldDateVar must be a valid SAS date variable.

  2. 2.

    Again, SAS help is excellent, if not immediately reachable. Delwiche and Slaughters’ 2nd edition lists some popular functions in Sects. 3.2 and 3.3.

  3. 3.

    Hint: PROC CONTENTS.

  4. 4.

    Why did this occur? Some zip code tabulation areas may not have had any deaths assigned to them, or they may have been male but not female deaths, or vice versa. The position of our male and female death numbers is 30 and 36, respectively.

  5. 5.

    We will find the file in the work library.

  6. 6.

    How many observations would you have if you concatenated using a SET statement?

  7. 7.

    International Classification of Diseases, 9th edition is a widely utilized system that assigns numbers to diseases. It dates back to the work of William Farr in nineteenth-century England.

  8. 8.

    The data set of all myocardial infarction admissions in New York City from 1994 to 2004 we used in Chap. 1.

References

  1. Cavalieri P, Marovich P, Patetta MJ, Walsh S, Bond C, SAS Institute (2000) Statistics I: Introduction to anova, regression, and logistic regression: course notes. SAS Institute, Cary, NC

    Google Scholar 

  2. Daniel WW (2006) Biostatistics: a foundation for analysis in the health sciences 8th edition with SPSS software CD Rom 14.0 set (Wiley series in probability and statistics). Wiley, New York

    Google Scholar 

  3. Darroch J. (1997) Biologic synergism and parallelism. American Journal of Epidemiology Vol 145, No7, pp 661–668.

    Article  Google Scholar 

  4. Delwiche LD, Slaughter SJ (2008) The little SAS book: a primer. SAS Institute, Cary, NC

    Google Scholar 

  5. Hennekens CH, Buring JE, Mayrent SL (1987) Epidemiology in medicine. Lippincott Williamns & Wilkins, Philadelphia

    Google Scholar 

  6. Hosmer DW, Lemeshow S (2000) Applied logistic regression (Wiley series in probability and statistics). Wiley, New York

    Book  Google Scholar 

  7. Kelsey JL, Whittemore AS, Evans AS, Thompson WD (1996) Methods in observational epidemiology. Oxford University Press, Oxford, New York

    Google Scholar 

  8. Kleinbaum DG, Kupper LL, Nizam A, Muller KE (2007) Applied regression analysis and multivariable methods (Duxbury applied). Duxbury Press, North Scituate, MA

    Google Scholar 

  9. Patetta MJ, Amrhein J (2005) Categorical data analysis using logistic regression: course notes. SAS Institute, Cary, NC

    Google Scholar 

  10. Rothman KJ, Greenland S, Lash TL (2008) Modern epidemiology, 3rd Edition. Lippincott Williamns & Wilkins, Philadelphia

    Google Scholar 

  11. Schlesselman JJ. (1982) Case-control studies: design, conduct, analysis. Oxford University Press, Oxford, New York

    Google Scholar 

  12. Susser ES, Schwartz S, Morabia A, Bromet E (2006) Psychiatric epidemiology: searching for the causes of mental disorders. Oxford University Press, Oxford, New York

    Google Scholar 

Download references

Author information

Authors and Affiliations

Authors

Rights and permissions

Reprints and permissions

Copyright information

© 2013 Springer Science+Business Media New York

About this chapter

Cite this chapter

DiMaggio, C. (2013). Manipulating Data. In: SAS for Epidemiologists. Springer, New York, NY. https://doi.org/10.1007/978-1-4614-4854-9_5

Download citation

Publish with us

Policies and ethics