Undefined columns selected when subsetting data frame January 29, 2023 by Tarik You want rows where that condition is true so you need a comma: data[data$Ozone > 14, ]