Hi all, I have a data frame with huge rows and columns.
When I looked at the data, it has several garbage values need to be cleaned. For a sample I am showing you the frequency distribution of one variables Var1 Freq 1 : 3 2 ] 6 3 MSN 1040 4 YYZ 300 5 \\ 4 6 + 3 7. ?> 15 and continues. I want to keep those rows that contain only a valid variable value In this case MSN and YYZ. I tried the following *test <- dat[dat$Var1 == "YYZ" | dat$Var1 =="MSN" ,]* but I am not getting the desired result. I have Any help or idea? [[alternative HTML version deleted]] ______________________________________________ R-help@r-project.org mailing list -- To UNSUBSCRIBE and more, see https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting-guide.html and provide commented, minimal, self-contained, reproducible code.