Table of Contents»

 

Contributing Authors:

Ching-Ti Liu, PhD, Associate Professor, Biostatistics

Jacqueline Milton, PhD, Clinical Assistant Professor, Biostatistics

Avery McIntosh, doctoral candidate

 

 

This module will build additional skills in R programming by going beyound simple commands.

 

Outline:

 

Learning Objectives


By the end of this session students will be able to:

  1. Perform simple data manipulations: vectors (numeric, logical, character), missing values, index vectors, many-to-one, one-to-many merging
  2. Use grouped expression and if-else statements:
  3. Know how to write your own functions

Additional Tools:

> sort( c(1,55,-2,11) )

[1] -2  1 11 55

> sample(c("First","Second","Third","Fourth"), replace=F)

[1] "Fourth" "First"  "Third"  "Second"