# Categorical data with Continuous model

I am working with a dataset and am attempting to predict "gross" for a movie. All of the predictors that I have are continuous except for one: color. This categorical variable has two levels: "Black and White" and "Color". Does it make sense to include this categorical variable with all continuous variables such as "budget", "imdb score" and "duration". Would it make sense to code "Black and White"=1 and "Color"=2? If so, what is the easiest way to do this in R. Should I include this variable at all?

• R's lm() function converts this categorial value for you into a 2 new bivariate dummy variables/columns "is_white" and "is_black" (or similar name). You see these new columns reported when you call summary(lm()). – knb Apr 12 '17 at 8:34

This is not difficult in R. I'd just google 'fitting linear models in R'. The essence of what you want is a model of the form y ~ x1 + x2 + x3.