平行斜率模型
現在來配適一個「平行斜率」模型,使用數值型的解釋/預測變數 log10_size,以及此處為二元類別的變數 waterfront。與此模型對應的視覺化如下:
本練習屬於課程
在 Tidyverse 中進行資料建模
練習說明
以 log10_size 和 waterfront 作為預測變數,對 log10_price 配適一個多元迴歸。記得包含這些變數的資料框為 house_prices。
動手互動練習
試著完成這個範例程式碼,體驗一下這個練習。
# Fit model
model_price_4 <- lm(___,
data = ___)
# Get regression table
get_regression_table(model_price_4)