Q:

How to delete columns in a dataset that have binomial variables

The dataset named data has both categorical and continuous variables.  I would like to the delete categorical variables.
I tried:
data.1 <- data[,colnames(data)[[3L]]!=0]
No error is printed, but categorical variables stay in data.1. Where are problems ?
The summary of "head(data)" is
id        1,2,3,4,... 
age       45,32,54,23,...
status    0,1,0,0,...
 ...
(more variables like as I wrote above)

All variables are defined as "Factor".

A:

What are you trying to do with that code? First of all, colnames(data) is not a list so using [[]] doesn't make sense. Second, The only thing you test is whether the third column name is not equal to zero. As a column name can never start with a number, that's pretty much always true. So your code translates to :
data1 <- data[,TRUE]

Not what you intend to do.
I suppose you know the meaning of binomial. One way of doing that is defining your own function is.binomial() like this :
is.binomial <- function(x,na.action=c('na.omit','na.fail','na.pass'){
    FUN <- match.fun(match.arg(na.action))
    length(unique(FUN(x)))==2
}

in case you want to take care of NA's. This you can then apply to your dataframe :
data.1 <- data[!sapply(data,is.binomial)]

This way you drop all binomial columns, i.e. columns with only two distinct values.

