Hello,
I have empty row values for some of the entries in a column titled start_station_id. I would like to delete every row that has no value in that particular column. I have tried
month1[!month1$start_station_id == "", " ",]
but the rows don't get deleted. The column is the the 6th in the data frame if that is relevant here.
Is there another solution?
install.packages("tidyverse")
library(tidyverse)
setwd("/cloud/project")
month1 <- read.csv("202101-divvy-tripdata.csv")
month1$started_at <- ymd_hms(month1$started_at)
month1$ended_at <- ymd_hms(month1$ended_at)
month1$time_diff_mins <- round(difftime(month1$ended_at,month1$started_at, units="mins"), 2)
month1[!month1$start_station_id == "", " ",]