This code is an example of a Shiny app that uses the randomForest package to fit a Random Forest model to predict the quality of red wine. The app loads data from a CSV file containing information about various physicochemical properties of red wine and their corresponding quality ratings. The data is split into training and testing sets, and a Random Forest model is fit to the training data. The server component of the app defines a reactive function that takes user input for the physicochemical properties of a wine and uses the fitted model to predict its quality. The function also calculates the accuracy of the model on the test set and returns text with the prediction and the accuracy of the model. The UI is built using a fluidPage layout that contains a title panel and a sidebar layout. The sidebar panel contains numeric input elements for each of the physicochemical properties of the wine, as well as an action button to submit the input values. The main panel contains a text output element to display the result of the prediction. Finally, the app is run using the shinyApp function with the defined UI and server components. https://jumperche.shinyapps.io/redWine/
-
Notifications
You must be signed in to change notification settings - Fork 0
jumperche/R
Folders and files
Name | Name | Last commit message | Last commit date | |
---|---|---|---|---|
Repository files navigation
About
No description, website, or topics provided.
Resources
Stars
Watchers
Forks
Releases
No releases published
Packages 0
No packages published