I have a "list" of character vectors.  I'm trying to see if there is a way
(in a single line, without a loop) to pull out the first element of all the
vectors contained in the list.

 

listOfVectors[1:length(listOfVectors][1]

 

doesn't work.

 

==========================

If you want more details..

Here is my listOfVectors which is called "uuu"

> uuu[order(uuu)]

[[1]]

[1] "pt1pg"      "multi.expr"

 

[[2]]

[1] "1ng"        "ml"         "fluor.expr"

 

[[3]]

[1] "1pg"        "ml"         "fluor.expr"

 

[[4]]

[1] "10ng"       "ml"         "fluor.expr"

 

[[5]]

[1] "10pg"       "ml"         "fluor.expr"

 

I'm basically interested in getting the following elements:

"pt1pg", "1ng", "1pg", etc. as a list (or character vector)

 

Note, this might have an obvious solution but I claim Newbie status!

 

Thanks in advance!

-Scott

 

 

Scott Norton, Ph.D.

Engineering Manager

Nanoplex Technologies, Inc.

2375 Garcia Ave.

Mountain View, CA 94043

www.nanoplextech.com

 


	[[alternative HTML version deleted]]


