I have a dataset that includes two variables called "NAME" and "TITLE".
NAME should simply be an individual's birth name (e.g. "John William Figueroa") and title should be anything appended to the end (e.g. OBE, MD, PhD, JD). Trouble is, a lot of entries instead have this information in the NAME column so that it reads "John William Figueroa, PhD".
Is there an easy way to use the comma (very frequently present) to shift the title into the next column? I'd use the "split" function but I don't want this broken into two new variables, just want to shift some of the information one line over. Thanks so much for your time!
Best,
Chuck
Related Posts with Splitting An Instance into two existing attributes
How to create an iterative procedure to check variable by variable whether a given observation satisfies some criteria - string variablesDear all, I am working with string data and I would like to retrieve the most important word from a…
Extracting first five and last three parts from string variable.Dear Stata users, I hope you are staying safe. I have data set with code and name like this. Code…
if time dummies are dropped in system GMM; How we can interpret? - xtabond2Hello, I need your help. I hope you are staying safe. I have an unbalanced panel dataset. It includ…
Which family and link for GLM?Hello! I am trying to find the right model that matches the distribution of my data. I use cross-se…
Clustering standard errors at industry levelDear Statalist members, Currently my data size is about 12,000 observations. The topic of my thesis…
Subscribe to:
Post Comments (Atom)
0 Response to Splitting An Instance into two existing attributes
Post a Comment