2024-02-05

##         
##          1Fam 2fmCon Duplex Twnhs TwnhsE
##   1.5Fin  289     19      5     1      0
##   1.5Unf   18      1      0     0      0
##   1Story 1222     16     57    19    167
##   2.5Fin    7      1      0     0      0
##   2.5Unf   18      4      2     0      0
##   2Story  703     18     25    71     56
##   SFoyer   48      2     19     6      8
##   SLvl    120      1      1     4      2
## [1] 2425   82

Graph

Code

df1\(ExterQual <- factor(df1\)ExterQual, levels = c(“Ex”,“Gd”,“TA”, “Fa”)) df1\(KitchenQual <- factor(df1\)KitchenQual, levels = c(“Ex”,“Gd”,“TA”, “Fa”, “Po”))

ggplot(data = df1, aes(x = YearBuilt, y = SalePrice/1000)) + geom_point() + aes(colour = KitchenQual) + facet_wrap(~ExterQual, ncol = 4) + theme(legend.position = “right”) + theme(plot.title = element_text(color=“black”, size=14, face=“bold.italic”), axis.title.x = element_text(color=“black”, size=16, face=“bold”), axis.title.y = element_text(color=“black”, size=16, face=“bold”), axis.text.x = element_text(color = “darkslategray”,size = 10), axis.text.y = element_text(color = “darkslategray”, size = 10, hjust = 1)) + labs(title=“Year Built vs. Sale Price {Facet: External Qual., Colors: Kitchen Qual.”) + scale_color_manual(values=c(“indianred4”, “indianred3”, “indianred2”, “indianred1”, “indianred”))

Conclusion

  • correlations…

Confounding Variables

  • year built
  • etc…