Reputation: 613
I have a csv file like
Data.csv
Id,Name,City
23,radu,Los Angeles
34,tree,Chicago
rtet,great,Miami
rtet,francis,Paris
where
record <- read.csv("Data.csv",header=TRUE);
Identity <- record$Id
I used
gsub("rtet","67",Identity)
But it does not work.
How to replace "rtet" in the csv file with "67" in R? New to R.Any help is appreciated.
Upvotes: 1
Views: 1501