Hi
Im pretty new to R and I have run in to a problem. How do I name all the
levels in this list.

Lev1 <- c("A1","A2")
Lev2 <- c("B1","B2")
Lev3 <- c("C1","C2")

MyList <- lapply(TEST1,function(x){
assign("x",x,where=1)
lapply(TEST2,function(y){
assign("y",y,where=1)
lapply(TEST3,function(z){
paste(unlist(x),unlist(y),unlist(z))
})})})

I would like to name the different levels in the list with the differnt
inputs.
So that the first level in named by the inputs in Lev1 and the second Level
by the inputs in Lev2, and so on

I would then like to use this call

MyList$A1$B1$C1
> "A1 B1 C1"

Regards Tom
-- 
View this message in context: 
http://www.nabble.com/Naming-Lists-tf4228968.html#a12030717
Sent from the R help mailing list archive at Nabble.com.

______________________________________________
R-help@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
and provide commented, minimal, self-contained, reproducible code.

Reply via email to