Skip to content

Classifying the various quality of wine and analyzing the data led to the prediction of wine quality using some Machine Learning Algorithms.

Notifications You must be signed in to change notification settings

prateekagr21/Wine-Quality-Analysis

Repository files navigation

Wine-Quality-Analysis !!

Analysis and Classification of the quality of wine using Machine Learning Algorithms.

wine1

Wine quality, as Maynard Amerine once said, is easier to detect than define. This is partially due to quality being primarily subjective, and strongly influenced by extrinsic factors.

Nonetheless, most serious wine connoisseurs tend to agree on what constitutes wine quality, that is, what they subjectively have come to like through extensive tasting. Although disappointingly nebulous, it has still been sufficient to guide grape growers and winemakers in their choice of the procedures they use.

Wine quality is the result of a complex set of interactions, which include geological and soil variables, climate, and many variables, climate, and many viticultural decisions

What constitutes wine quality is often a reflection of cultural percepts, training, and experience. It is also undoubtedly influenced by the sensory acuity and intention to seriously assess the wine’s attributes.

Nonetheless, quality does have components, independent of individual tasters, on which there is general agreement. This especially applies to negative factors, such as off-odors. There is less accord on what constitutes positive quality aspects.

wine3

For Solving this Usecase, What I have done is :

  • Collected the data and organized it to form a meaningful dataset.
  • Checked for null values and took care of it.
  • Observed the data to form meaningful insights!

  • Did Exploratory Data Analysis on the dataset.
  • Used correlations to form a heatmap.
  • Visualizations were made by using Matplotlib and Seaborn Libraries..!!

Did Data Pre-Processing :

  • Made Binary Classifications Using Label Encoder
  • and Standard Scaler
    to fit and transform Numerical and Categorical Column values.

And then I made my model for the Prediction :

  • Did Data Preprocessing.
  • Independent and Dependent Features.
  • Did Train-Test split

Trained my Model using :

Random Forest Classifier

  • Predicted for the data
  • Finded Accuracy score
  • Plotted Confusion Matrix
  • And at last, Classification report.
  • And Analyzed the key factors responsible for prediction.

Support Vector Machine

  • Predicted for the data
  • Finded Accuracy score
  • Plotted Confusion Matrix
  • And at last, Classification report.

Using K Neighbors Classifier

  • Predicted for the data
  • Finded Accuracy score
  • Plotted Confusion Matrix
  • And at last, Classification report.

wine2

And for the conclusion -

From the above three trained Models, It can be seen that
With the Accuracy of around 88%,
the Random Forest Classifier model performed slightly better than SVM and KNN models.

About

Classifying the various quality of wine and analyzing the data led to the prediction of wine quality using some Machine Learning Algorithms.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published