"Moises Hassan" <[EMAIL PROTECTED]> writes:

> It works great, except that in the case where only one column is left,
> it returns a vector and the column name is lost. How can you avoid that
> behavior?

Just add drop=FALSE to the indexing i.e. A[,cond,drop=FALSE] 


-- 
   O__  ---- Peter Dalgaard             Blegdamsvej 3  
  c/ /'_ --- Dept. of Biostatistics     2200 Cph. N   
 (*) \(*) -- University of Copenhagen   Denmark      Ph: (+45) 35327918
~~~~~~~~~~ - ([EMAIL PROTECTED])             FAX: (+45) 35327907

______________________________________________
[EMAIL PROTECTED] mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html

Reply via email to