I am practicing Linear Regression on the Airbnb dataset. The VIF for 2 dummy variables 'room_type_Entire home/apt' and 'room_type_Private room' is coming as '9.546159' and '9.116464'. These dummy variables I got after applying OHE and dummy encoding on the categorical variable 'room_type' which had 3 categories initially. Can I drop one of the dummy variables say 'room_type_Entire home/apt'? In general if we have k dummy variables out of which j(j<k) are having VIF > 5 can we drop j-1 dummy variables?
$\begingroup$
$\endgroup$
11
-
1$\begingroup$ Welcome to Cross Validated! Why drop any of the variables? $\endgroup$– DaveCommented Jul 18, 2023 at 16:34
-
$\begingroup$ I am dropping 'room_type_Entire home/apt' because I want to handle multicollinearity in the design matrix. There seem to a linear dependence b/w the 'room_type_Entire home/apt' and the 'room_type_Private room'. Based on the value for VIF being greater than 5 I came to this decision. $\endgroup$– ShriCommented Jul 18, 2023 at 16:46
-
$\begingroup$ Do you mean that you want to drop an entire factor or just one level after you one-hot encode a categorical variable? $\endgroup$– DaveCommented Jul 18, 2023 at 16:47
-
2$\begingroup$ Of course you can drop any variables you like. But basing your decision solely on VIF is unwise and often will result in a poor regression. You need to examine the correlation structure in greater detail than that and you need to consider more clearly why you are performing this regression. Can you explain your objectives? $\endgroup$– whuber ♦Commented Jul 18, 2023 at 16:52
-
$\begingroup$ I want to determine the 'price' based on the features. These are the features I got after the data pre-processing step: accommodates(float) bathrooms(float) cleaning_fee(0 for True 1 for False) instant_bookable(0 for True 1 for False) review_scores_rating(float) bedrooms(float) beds(float) room_type_Entire home/apt(dummy_variable) room_type_Private room (dummy_variable) cancellation_policy_flexible(dummy_variable) cancellation_policy_moderate(dummy_variable). Also, the correlation co-efficient b/w the 'room_type_Entire home/apt' and 'room_type_Private room' is coming as -0.94. $\endgroup$– ShriCommented Jul 18, 2023 at 17:04
|
Show 6 more comments