''' Types of plots In this exercise we will explore Matplotlib and the types of plots that can be produced. Chosing the correct plot to represent your data is an important skill, and knowing the available plot types helps to make a good decision. The plot types we will discuss are: scatterplot, histogram, bar plot, boxplots, and adding errorbars. ''' ''' Exercise A: Scatterplot Make a scatterplot of the first 10 Fibonacci numbers. Why is a scatterplot an appropriate plot to visualise these? ''' # Your code here ''' Exercise B: Histogram and Bar plot A research group takes a questionnaire. The scientists are interested in the age distribution of the correspondents. The ages are [14, 14, 15, 16, 17, 19, 19, 20, 22, 22, 25, 26, 27, 27, 27, 30, 33, 33, 34, 34, 34, 35, 36, 37, 37, 39, 42, 42, 43, 44, 45, 45, 45, 47, 49, 50, 50, 51, 52, 53, 55, 56, 56, 56, 56, 57, 58, 85, 60, 63, 64, 66, 66, 69, 70, 73, 74, 76] Part I. Make a histogram of the age distributions, with one bin each for ages 10 - 19, 20 - 29, etc. until 70 - 79. Which age group was most represented in this research? Part II. For this data, also create a barplot. Note that for a barplot, you need to give the heights of the bars yourself! If you want an extra challenge, write a function that counts the number of participants in their respective age groups for you. Else, use your histogram or count by hand. ''' # Your code here ''' Exercise C: Boxplot Part I. In Python, we can generate a random integer between 10 and 79 using the command `np.random.randint(10, 80)`. Using a `for` loop, create a dataset of 50 participants with random ages between 10 and 80. Make a boxplot of this distribution. Part II. Now, repeat this process to create 4 datasets of randomly distributed ages, and plot them as boxplots in the same plot. Compare the results - are they as expected given that we used a random generating process? Increase the number of participants to 2,000. Are these results more or less like what you expected? What does this tell you about the reliability between participant number in a study, and reliability of the study results? ''' # Your code here ''' Exercise D: Lineplot with errorbars A researcher measures the deviation of the temperature from room temperature of a reaction over time. They measure every second, starting at 0 and ending at 20. Their results are (in K): [304.1, 306.6, 308.7, 310.7, 313.2, 316.8, 320.4, 323.8, 326.3, 329.3, 331.1, 332.1, 333.3, 332.1, 331.1, 329.3, 326.3, 323.8, 320.4, 316.8, 313.2] The machine used for measurements has an error of 5 %. Create a plot of the measured data and add errorbars to the measurement points. ''' # Your code here