Hi,
I am processing people names, and I find sometimes the names are in native language. For example, names are spelled like "André " or "Martínez". Currently I am manually tranforming such names into English one by one (e.g. "Andre" or "Martinez"), but there are so many names that I feel a little overwhelmed. I would really appreciate it if someone could kindly teach me a quicker way. Thank you very much in advance.
If your problem is caused by different language encodings then this paper may help, in particular the conversion macro included:
http://support.sas.com/resources/papers/Multilingu
Well, its a tricky one, as names could be anything. My suggestion would be to create a coded list. To do this, do a select distinct values of name from your dataset. Then go through the distinct list and add in the decoded value, e.g.:
CODE DECODE
André Andre
...
Then simply use that coded list to replce the original. I would imagine that you will need to do at least some manual review, I mean you could setup some programmatic conversions, but some will just be really random.
Hi Bruno,
Thank you very much for the useful tip. In order to use the function of BASEDCHAR, should I install "National Language Support (NLS)" as an addition? Since currently the log suggests that "The function BASECHAR is unknown, or cannot be accessed"...
Yes, you should install NLS.
SAS Innovate 2025 is scheduled for May 6-9 in Orlando, FL. Sign up to be first to learn about the agenda and registration!
Learn how use the CAT functions in SAS to join values from multiple variables into a single value.
Find more tutorials on the SAS Users YouTube channel.
Ready to level-up your skills? Choose your own adventure.