Standardized regression coefficients with dummy variables in R vs. SPSS
问题 I came across a puzzling difference in standardized (beta) coefficients with linear regression model computed with R and SPSS using dummy coded variables. I have used the hsb2 data set and created a contrast (dummy coding), so that the third category is the reference. Here is the R code: # Read the data hsb2 <- read.table('https://stats.idre.ucla.edu/stat/data/hsb2.csv', header = TRUE, sep = ",") # Create a factor variable with respondents' race hsb2$race.f <- factor(hsb2$race, labels = c(