[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

st: AW: text to columns

From   "Martin Weiss" <[email protected]>
To   <[email protected]>
Subject   st: AW: text to columns
Date   Tue, 17 Nov 2009 21:28:35 +0100



input str30 myvar 


split myvar, parse(_ -)
list, noobs


-----Ursprüngliche Nachricht-----
Von: [email protected]
[mailto:[email protected]] Im Auftrag von Keith Dear
Gesendet: Dienstag, 17. November 2009 21:27
An: [email protected]
Betreff: st: text to columns

Is there a utility to turn a string variable with values like 
into four variables (or whatever it takes) rs1805005, chr16, 88513145, 
88513 ?
A colleague tells me "Excel is easy using Text to columns and following 
the prompts, but it irritates me not to be able to do it in Stata!"
(btw I consider it a minor personal victory that the people I work with, 
some of them, sometimes, no longer write STATA.)

Dr Keith Dear
Senior Fellow
National Centre for Epidemiology and Population Health
ANU College of Medicine, Biology and Environment
Building 62, cnr Mills and Eggleston Roads
Australian National University
Canberra ACT 0200 Australia 

T: 02 6125 4865
F: 02 6125 0740
M: 0424 450 396

CRICOS provider #00120C

*   For searches and help try:

*   For searches and help try:

© Copyright 1996–2024 StataCorp LLC   |   Terms of use   |   Privacy   |   Contact us   |   What's new   |   Site index