I am working in R on data set of 104500 observations. I want to delete rows based on a column name "state" that has values "TX" and "NY".
I am using the following code
customers <- customers[customers$State != "TX"]
I'm getting the following error
Error: Length of logical index vector must be 1 or 11 (the number of rows), not 104541
Can anyone please help me with this?