Challenge

Project 2

all the questions can be done in Python and R. but got no information. therefore I have to write it in the box;

  1. Display the data of white wine and red wine:

    • Display the rows and columns of the "winequality-white" and "winequality-red" datasets.
  2. Get the size of both white wine and red wine:

    • Count the number of rows and columns in each dataset.
  3. Get the number of null in both types of wines:

    • Check if there are any missing values (null) in each dataset and count them.
  4. Check for duplicates and remove them in both types of wine data:

    • Identify if there are any duplicate rows in each dataset and remove them.
  5. Get the number of unique values in all Features and print them:

    • Count the unique values in each column (feature) of both datasets.
  6. Print the mean density of both the sets:

    • Calculate the average density for the "winequality-white" and "winequality-red" datasets.
  7. Combine both datasets with the color of the wine in a column:

    • Add a new column called "wine_type" to each dataset with values "white" and "red" respectively.
  8. Remove the null values if any:

    • Remove any rows that have missing values in either dataset.
  9. Remove the outliers if any:

    • Identify and remove any extreme values that deviate significantly from the rest of the data in each dataset.
  10. Do wines with higher alcohol content receive better ratings?

    • Analyze the relationship between alcohol content and quality ratings to determine if higher alcohol content correlates with higher ratings.
  11. Find correlation between citric acid content and pH:

    • Calculate the correlation coefficient between citric acid content and pH values.
  12. Find regression of pH on citric acid:

    • Perform a regression analysis to predict pH based on citric acid content.
  13. Find how many variables are independent:

    • Determine the number of independent variables (features) in each dataset.
  14. Create a new column as the acidity level:

    • Divide the data into five groups based on acidity levels, categorized as "High," "Moderately High," "Medium," and "Low" using pH values.
  15. Find the mean quality of each acidity level with groupby:

    • Calculate the average quality rating for each acidity level using the "groupby" function.
  16. Is a certain type of wine (red or white) associated with higher quality?

    • Compare the average quality rating for red and white wines to identify if one type tends to have higher quality.
  17. Select samples with alcohol content less than the median:

    • Filter and extract samples with alcohol content lower than the median value.
  18. Get the quality rating for the low alcohol and high alcohol groups:

    • Calculate the average quality rating for samples with low and high alcohol content.
  19. Do sweeter wines get more ratings?

    • Analyze if wines with higher residual sugar content tend to receive better ratings.
  20. Get the number of counts based on ratings and color of wine:

    • Count the occurrences of each rating for red and white wines.
  21. Is the density of red wine and white wine similar?

    • Compare the density distribution of red and white wines to determine similarity.
  22. Is the confidence interval for the differences of the proportion of white wine with rating 3 and the proportion of red wine with rating 3?

    • Calculate the confidence interval for the difference in proportions of white and red wines with rating 3.
Your portfolio, next

Ship work like this
in your own course.

Talk to a career counsellor

Free 20-minute call. We'll map the right course to where you want to work.

By submitting you agree to our Terms and Privacy Policy.