R cleaning up a character string and converting it into a numeric
I have a character string
abc <- "Â 267750Â"
class(abc)
"character"
What to I need to do to abc to get rid of “ ” and convert it from character to numeric.
Perhaps as.numeric will work but I need to get rid of “ ” first.
I want to convert the above to:
abc
267750
class(abc)
"numeric"
Thank you for your help.
You can parse out what you don’t want with regular expressions:
Returns
532.398.Edit
This is now in
taRifx: