Hi,
I would to get the first letter of a word like:
> title_cat
TitleCat
1 Training
I would like T from Training!
Thnaks a lot for your help
Sabine
-
Téléchargez le ici !
[[alternative HTML version deleted]]
___
or What about;
> strsplit("Training", split="")[[1]][1]
[1] "T"
Ken Knoblauch
Inserm U371, Cerveau et Vision
Department of Cognitive Neurosciences
18 avenue du Doyen Lepine
69500 Bron
France
tel: +33 (0)4 72 91 34 77
fax: +33 (0)4 72 91 34 61
portable: 06 84 10 64 10
http://w
Navarre Sabine wrote:
> Hi,
> I would to get the first letter of a word like:
>
>
>>title_cat
>
>TitleCat
> 1 Training
>
> I would like T from Training!
>
> Thnaks a lot for your help
>
substr(title_cat,1,1)
Uwe Ligges
> Sabine
>
>
> --
Use substring() or substr().
Andy
> From: Navarre Sabine
>
> Hi,
> I would to get the first letter of a word like:
>
> > title_cat
>TitleCat
> 1 Training
>
> I would like T from Training!
>
> Thnaks a lot for your help
>
> Sabine
>
>
> --
Sent: Wednesday, June 22, 2005 4:42 PM
Subject: [R] Is it possible to get the first letter of a word?
> Hi,
> I would to get the first letter of a word like:
>
>> title_cat
> TitleCat
> 1 Training
>
> I would like T from Training!
>
> Thnaks a lot for your
?substring
Navarre Sabine wrote:
> Hi,
> I would to get the first letter of a word like:
>
>
>>title_cat
>
>TitleCat
> 1 Training
>
> I would like T from Training!
>
> Thnaks a lot for your help
>
> Sabine
>
>
> -
>
> Télécharge
On Wed, 2005-06-22 at 16:42 +0200, Navarre Sabine wrote:
> Hi,
> I would to get the first letter of a word like:
>
> > title_cat
>TitleCat
> 1 Training
>
> I would like T from Training!
>
> Thnaks a lot for your help
>
> Sabine
There are multiple approaches, but you need to be c