Notice: On April 23, 2014, Statalist moved from an email list to a forum, based at statalist.org.
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: st: Creating new variable which includes the first 6 symbols of a 9 symbol string variable
From
Neil Shephard <nshephard@gmail.com>
To
statalist@hsphsun2.harvard.edu
Subject
Re: st: Creating new variable which includes the first 6 symbols of a 9 symbol string variable
Date
Tue, 21 Dec 2010 14:12:35 +0000
On Tue, Dec 21, 2010 at 2:04 PM, Dassen, Sander (Stud. SBE / Alumni)
<s.dassen@student.maastrichtuniversity.nl> wrote:
> I need to create a new variable which includes the first 6 symbols of a 9 symbol string variable.
>
> For example:
>
> Y7542C106
>
> should be returned as:
>
> Y7542C
See -man substr()-
Neil
--
"Our civilization would be pitifully immature without the intellectual
revolution led by Darwin" - Motoo Kimura, The Neutral Theory of
Molecular Evolution
Email - nshephard@gmail.com
Website - http://kimura-no-ip.org/
Photos - http://www.flickr.com/photos/slackline/
*
* For searches and help try:
* http://www.stata.com/help.cgi?search
* http://www.stata.com/support/statalist/faq
* http://www.ats.ucla.edu/stat/stata/