I would have a column where the data looks like this:
M999-00001
M999-00002
...
Is there a way to remove all the 'M's in the column in R?
We can use sub
df1[,1] <- sub("^.", "", df1[,1])
Or use substring
substring(df1[,1],2)
df1 <- data.frame(Col1 = c("M999-00001", "M999-0000"), stringsAsFactors=FALSE)