[R] drop unused levels in sqldf

glaporta glaporta at freeweb.org
Fri Aug 29 09:33:27 CEST 2008


Thanx guys,
practical and effective solutions.
Gianandrea


glaporta wrote:
> 
> Hi,
> sqldf is a fantastic package, but when the SELECT procedure runs unused
> levels remain in the output. I tried with the drop function, but without
> success. Do you have any suggestions?
> Thanx, Gianandrea
> 
> data(iris)
> require(sqldf)
> base<-sqldf("select * from iris where Species <> 'setosa'")
> str(base) # Species with 3 levels!
> 
> 

-- 
View this message in context: http://www.nabble.com/drop-unused-levels-in-sqldf-tp19196464p19215127.html
Sent from the R help mailing list archive at Nabble.com.



More information about the R-help mailing list