diff --git a/notebooks/R/.gitignore b/notebooks/R/.gitignore new file mode 100644 index 0000000..f8b1541 --- /dev/null +++ b/notebooks/R/.gitignore @@ -0,0 +1,5 @@ +data/ +.Rhistory +.RData +R.Rproj +.Rproj.user/ diff --git a/notebooks/R/main.R b/notebooks/R/main.R new file mode 100644 index 0000000..b12ec5d --- /dev/null +++ b/notebooks/R/main.R @@ -0,0 +1,10 @@ +folderIn <- "data" + +readNTS <- function(name,folderIn = "data"){ + data <- read.table(file.path(folderIn,"UKDA-5340-tab","tab",paste0(name,"_eul_2002-2022.tab")), sep="\t", header=TRUE) + return(data) +} + +NTS <- readNTS("individual",folderIn) +stage <- readNTS("stage",folderIn) +trip <- readNTS("trip",folderIn) \ No newline at end of file