I was trying to knit my Rmd file and I get this error.
Error in parse(text=x,srcfile=src): <text>:5:51: unexpected symbol 4: pred_test = predict(ames.bas,newdata=ames_test,estimator="BMA")5:resid_test=ames_test$price-exp(pred_test$fit) rmse_test
It stoped in line 402:
```{r}rmse_train = sqrt(mean((na.omit(ames_train$price - exp(pred_train$fit)))^2))
rmse_train
ames_test = ames_test %>% filter(Neighborhood != "Landmrk", Sale.Condition == "Normal")
pred_test = predict(ames.bas,newdata=ames_test,estimator = "BMA")
resid_test = ames_test$price - exp(pred_test$fit) rmse_test = sqrt(mean(resid_test^2))
resid_test
``` How can I resolve this problem? I tried everything that I could find among the answered questions