You can check the package leaps and in particular the function regsubsets() functions for model selection. As stated in the documentation: As stated in the documentation: Model selection by exhaustive search, forward or backward stepwise, or sequential replacement More @Wikipedia
Hover over any link to get a description of the article. Please note that search keywords are sometimes hidden within the full article and don't appear in the description or title.