# set paths and data names
<-
external.path "https://github.com/pharmaverse/intro-to-r-for-sas-programmers-workshop/blob/main/data"
<- ("data")
local.path <- file.path(local.path, "save_data")
subdir <- c(
files "adsl.RData",
"adsl.csv",
"adsl.sas7bdat",
"adsl_1.RData",
"adsl_2.RData",
"ae.rds",
"dm.rds",
"ds.rds",
"ex.rds",
"suppdm.rds",
"suppds.rds"
)
# external files (with path)
<- file.path(external.path, paste(files, "raw=true", sep = "?"))
urls # local files (with path)
<- file.path(local.path, files)
dest
# create data folder in wd
if (!file.exists(local.path)) {
dir.create(local.path)
# subdirectory
dir.create(subdir)
}
# download files if needed
download.file(urls, destfile = dest)
Introduction to R for SAS programmers
About
On this page you find the materials used in the workshop Introduction to R for SAS programmers taking place on January 17th, 2023. The recording of the workshop is available on the CDISC website.
The workshop provided an RStudio cloud work-space. To follow along on your local machine, create a new R-Project and paste / execute the following code-chunk in an R-Script or the R console. Executing the following chunk in R on your machine will create and populate a data folder in your current working directory.
Further material
You can’t get enough? Here is a resource to help transitioning from SAS to R.