Try this:

cbind(mynames[rep(seq(nrow(mynames)), sapply(lst, length)),], unlist(lst))

On Mon, Jun 14, 2010 at 9:06 AM, Yuan Jian <jayuan2...@yahoo.com> wrote:

> Hello,
>
> I could not find a clear solution for the follow question. please allow me
> to ask. thanks
>
> mynames=cbind(c('a','b'),c(11,22))
> lst=list(a=c(1,2), b=5)
>
> now I try to combine mynames and lst:
> a  1  11
> a  2  11
> b  5  22
>
> thanks
> jian
>
>
>
>
>        [[alternative HTML version deleted]]
>
>
> ______________________________________________
> R-help@r-project.org 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.
>
>


-- 
Henrique Dallazuanna
Curitiba-Paraná-Brasil
25° 25' 40" S 49° 16' 22" O

        [[alternative HTML version deleted]]

______________________________________________
R-help@r-project.org 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