predictions: Predictions Function: Generate predictions using classifiers from RWeka
Description
This function trains three different classifiers—Random Forest (RF), Support Vector Machine (SVM), and Logistic Regression (LR)—on the input dataset and returns their predictions.
Usage
predictions(Xdata, Ydata)
Value
A list containing predictions from the three models:
predictionRF
Predictions from the Random Forest (RF) model.
predictionSVM
Predictions from the Support Vector Machine (SVM) model.
predictionLR
Predictions from the Logistic Regression (LR) model.
Arguments
Xdata
Matrix. A dataset where rows represent observations and columns represent features.
Ydata
Vector. The actual response variable associated with each row in Xdata.
Details
The function utilizes the RWeka package to build three different classifiers:
Random Forest (RF), Support Vector Machine (SVM), and Logistic Regression (LR). It then
predicts the response variable for the input data using each of these models.
References
Davila-Pena, L., Saavedra-Nieves, A., & Casas-Méndez, B. (2024). On the influence of dependent features in classification problems: a game-theoretic perspective. arXiv preprint. tools:::Rd_expr_doi("10.48550/arXiv.2408.02481").