[R] How to generate labels or names?

Sean Davis sdavis2 at mail.nih.gov
Thu Jan 27 18:57:43 CET 2005


Note that sometimes it makes more sense to use a list than a labeled 
vector.

Sean

On Jan 27, 2005, at 12:26 PM, Spencer Graves wrote:

> ?paste
>
> One of its examples is
> paste("A", 1:6, sep = "")
> [1] "A1" "A2" "A3" "A4" "A5" "A6"
>
> spencer graves
>
> Eric Rodriguez wrote:
>
>> Hi,
>>
>> I'm new to R and I would like to generate labels like data.frame does
>> : "V1 V2 V3...".
>> I'm trying to generate a N vector with label such as "Lab1 Lab2 ... 
>> LabN".
>>
>> I guess this is pretty easy when you know R ;)
>>
>> Thanks for help
>>
>> Eric
>>
>> ______________________________________________
>> R-help at stat.math.ethz.ch mailing list
>> https://stat.ethz.ch/mailman/listinfo/r-help
>> PLEASE do read the posting guide! 
>> http://www.R-project.org/posting-guide.html
>>
>
> ______________________________________________
> R-help at stat.math.ethz.ch mailing list
> https://stat.ethz.ch/mailman/listinfo/r-help
> PLEASE do read the posting guide! 
> http://www.R-project.org/posting-guide.html




More information about the R-help mailing list