[R] drop.terms and [.terms ignores intercept

Niels Richard Hansen Niels.R.Hansen+lists at math.ku.dk
Wed Sep 29 10:29:19 CEST 2010


Dear R-help list

The functions drop.terms and [.terms ignores if the intercept
has been explicitly removed. Is that a deliberate feature?

For instance,

drop.terms(terms(~a+b-1),1)
terms(~a+b-1)[2]

R version 2.12.0 Under development (unstable) (2010-09-13 r52905)

Best, Niels

-- 
Niels Richard Hansen                     Web:   www.math.ku.dk/~richard	
Associate Professor                      Email: Niels.R.Hansen at math.ku.dk
Department of Mathematical Sciences             nielsrichardhansen at gmail.com
University of Copenhagen                 Skype: nielsrichardhansen.dk	
Universitetsparken 5                     Phone: +45 353 20783 (office)	
2100 Copenhagen Ø                               +45 2859 0765 (mobile)
Denmark



More information about the R-help mailing list