Path: blob/master/07_Visualization/Tips/Solutions.ipynb
548 views
Kernel: Python 3
Tips
Introduction:
This exercise was created based on the tutorial and documentation from Seaborn The dataset being used is tips from Seaborn.
Step 1. Import the necessary libraries:
In [18]:
Step 2. Import the dataset from this address.
Step 3. Assign it to a variable called tips
In [10]:
Out[10]:
Step 4. Delete the Unnamed 0 column
In [12]:
Out[12]:
Step 5. Plot the total_bill column histogram
In [37]:
Out[37]:
Step 6. Create a scatter plot presenting the relationship between total_bill and tip
In [46]:
Out[46]:
<seaborn.axisgrid.JointGrid at 0x1197d84d0>
Step 7. Create one image with the relationship of total_bill, tip and size.
Hint: It is just one function.
In [44]:
Out[44]:
<seaborn.axisgrid.PairGrid at 0x11844c090>
Step 8. Present the relationship between days and total_bill value
In [51]:
Out[51]:
Step 9. Create a scatter plot with the day as the y-axis and tip as the x-axis, differ the dots by sex
In [61]:
Out[61]:
Step 10. Create a box plot presenting the total_bill per day differetiation the time (Dinner or Lunch)
In [58]:
Out[58]:
Step 11. Create two histograms of the tip value based for Dinner and Lunch. They must be side by side.
In [63]:
Out[63]:
Step 12. Create two scatterplots graphs, one for Male and another for Female, presenting the total_bill value and tip relationship, differing by smoker or no smoker
They must be side by side.
In [65]:
Out[65]:
BONUS: Create your own question and answer it using a graph.
In [ ]: