I have a data set 382 rows and  63 columns.  One of the columns is bay, and there are 6 bays.  But, the number of levels for this factor is 7 when it should be six because there is some 'blank' level "".  When I subset for the blank level "", I get 0 rows.  What in my data could be causing this?  Thanks.

>    dim(datmtx)
[1] 382  63


>     datmtx$bay
  [1] TB TB TB TB TB TB TB TB TB TB TB TB TB TB TB TB TB TB TB TB TB TB TB TB TB TB TB TB TB TB TB TB TB TB TB TB TB TB TB TB TB TB TB TB TB TB TB TB TB TB
 [51] TB TB TB TB TB TB TB TB TB TB TB TB TB TB TB TB TB TB TB TB TB TB TB TB TB TB TB TB TB TB TB TB TB TB TB TB TB TB TB TB TB TB TB TB TB TB TB TB TB TB
[101] TB TB TB TB TB TB TB TB TB TB TB TB TB TB TB TB TB TB TB TB TB TB TB TB TB TB TB TB TB TB TB TB TB TB TB TB TB TB TB TB TB TB TB TB TB HI TB HI TB TB
[151] TB TB TB TB TB HI TB HI HI HI TB HI HI HI TB HI HI HI HI HI HI HI HI TB TB TB TB CH CH TB CH CH CH CH CH CH CH CH CH CH TB TB CH CH CH CH CH CH CH CH
[201] CH CH CH CH CH CH CH CH CH CH CH CH CH CH CH CH CH CH CH CH TB HI HI HI TB HI HI TB TB TB TB TB TB TB TB TB TB HI TB TB TB TB TB TB TB TB TB TB TB TB
[251] TB HI HI HI CH CH CH CH CH CH CH CH CH CH HI HI CH CH CH CH CH CH CH CH CH CH CH CH TB TB TB TB TB TB TB TB TB TB CH CH AP AP AP AP AP AP HI HI HI CH
[301] CH CH CH AP AP TB TB AP AP AP AP AP AP SA BB BB TB TB TB TB AP HI AP SA AP HI AP AP HI HI TB HI AP SA AP AP AP AP AP AP AP AP SA AP AP SA AP AP AP SA
[351] SA SA AP AP AP CH CH CH CH CH AP BB BB BB BB BB TB CH CH CH CH CH CH CH CH CH CH CH CH CH CH CH
Levels:  AP BB CH HI SA TB

>     levels(datmtx$bay)
[1] ""   "AP" "BB" "CH" "HI" "SA" "TB"

>     nlevels(datmtx$bay)
[1] 7

David Chagaris
Associate Research Scientist
Florida Fish and Wildlife Conservation Commission
Florida Fish and Wildlife Research Institute
100 8th Ave SE
St. Petersburg, FL  33701
(727) 896-8626 ext. 4305
(727) 893-1374 fax


	[[alternative HTML version deleted]]

