From 1859f31449653c1523599e15710c16bf4cc08de7 Mon Sep 17 00:00:00 2001 From: josephwysocki Date: Mon, 3 Aug 2020 13:21:24 -0400 Subject: [PATCH] Combined data frames * Added column for wine type prior to bind --- project2.R | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/project2.R b/project2.R index c2ccb19..6861e90 100644 --- a/project2.R +++ b/project2.R @@ -10,3 +10,9 @@ data_R<-read.table("wineQualityReds.csv", header=TRUE, sep=",")[,-1] table(is.na(data_W)) table(is.na(data_R)) +# Add column indicating the wine type +data_W$type <- 'white' +data_R$type <- 'red' + +# Combine the two dataframes +data <- rbind(data_W,data_R)