Including multiple variables

One method to build a performance-prediction model could be using multiple variable regression models. A linear estimation should only include variables with minimal linear connection among them. As we have just seen, our explanatory variables are more or less independent of each other, which is great. It is bad news, though, that these variables individually also have low correlation with the dependent variable, TRS.

To get the best linear estimation, we may choose from several methods. One option is to first include all variables and ask R to drop step by step the one with the lowest significance (step-wise method). Under another widely used method, R could start with one variable only and enter stepwise the next ...

Get Mastering R for Quantitative Finance now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.