Challenge The objective of this exercise is to discriminating between three species of Iris from the...
Fantastic news! We've Found the answer you've been seeking!
Question:
Transcribed Image Text:
Challenge The objective of this exercise is to discriminating between three species of Iris from the measurements of their petals and sepals. Your challenge will be to write your code in 20 lines or less, not including comment lines. Out [2]: array([[1., 5.1, 3.5, 1.4, 0.2, 1. ], [2., 4.9, 3., 1.4, 0.2, 1. ], [3., 4.7, 3.2, 1.3, 0.2, 1. ], 4.6, 3.1, 1.5, 0.2, 1. 1, 5. 3.6, 1.4, 0.2, 1. ]]) In [ ]: In [ ]: In [ ]: [4. [5. 2 2 # The name of each column is placed in the following list: column_name = ['num', 'sepal length', 'sepal Width', 'petal length', 'petal width', 'species'] # Using a for Loop and the NumPy Library: # print the minimum value of each column # print the maximum value of each column # print the mean of each column # Create a histogram showing the number of flowers for each species # Create a subplot that shows 4 histograms # The first histogram shows the categories of sepal Lengths # The second histogram shows the categories of sepal widths # The third histogram shows the categories of petal Lengths # The fourth histogram shows the categories of petal widths #Label the x-axis of each histogram by the name of the column you are looking at #make sure the the Labels do not overlap with the figures In [ ]: # Create a subplot show two plots on the same row. # for the first subplot, use plt.scatter to graph the sepal width as a function of the sepal Length # for the second subplot, use plt.scatter to graph the petal width as a function of the petal Length # Label the x and y axis Challenge The objective of this exercise is to discriminating between three species of Iris from the measurements of their petals and sepals. Your challenge will be to write your code in 20 lines or less, not including comment lines. Out [2]: array([[1., 5.1, 3.5, 1.4, 0.2, 1. ], [2., 4.9, 3., 1.4, 0.2, 1. ], [3., 4.7, 3.2, 1.3, 0.2, 1. ], 4.6, 3.1, 1.5, 0.2, 1. 1, 5. 3.6, 1.4, 0.2, 1. ]]) In [ ]: In [ ]: In [ ]: [4. [5. 2 2 # The name of each column is placed in the following list: column_name = ['num', 'sepal length', 'sepal Width', 'petal length', 'petal width', 'species'] # Using a for Loop and the NumPy Library: # print the minimum value of each column # print the maximum value of each column # print the mean of each column # Create a histogram showing the number of flowers for each species # Create a subplot that shows 4 histograms # The first histogram shows the categories of sepal Lengths # The second histogram shows the categories of sepal widths # The third histogram shows the categories of petal Lengths # The fourth histogram shows the categories of petal widths #Label the x-axis of each histogram by the name of the column you are looking at #make sure the the Labels do not overlap with the figures In [ ]: # Create a subplot show two plots on the same row. # for the first subplot, use plt.scatter to graph the sepal width as a function of the sepal Length # for the second subplot, use plt.scatter to graph the petal width as a function of the petal Length # Label the x and y axis
Expert Answer:
Answer rating: 100% (QA)
import numpy as np import matplotlibpyplot as plt data nparray1 51 35 14 02 1 2 49 3 14 02 1 3 47 32 ... View the full answer
Related Book For
Practicing Statistics Guided Investigations For The Second Course
ISBN: 9780321586018
1st Edition
Authors: Shonda Kuiper, Jeff Sklar
Posted Date:
Students also viewed these programming questions
-
Inductive Reasoning in Your Life. Give an example of a situation in which you used inductive reasoning in everyday life. Explain the situation, describe the steps in your thinking, and explain why it...
-
The count rate of nuclear radiation coming from a radioactive sample containing 1281 varies with time as follows Time t(minute): Count rate R(x10 s-): The mean life is 25 min 36 min 50 min 30 min 0...
-
As a manager, you must be able to identify the growth and diversification goals your organization hopes to achieve and choose the most successful ways in which to meet them, whether through mergers,...
-
7 8 0 The following data is provided for the Piedmont Corporation. All costs are actual costs. Complete the cost flows diagram attached to this problem and calculate CGM and CGS. Prepare journal...
-
Write an essay in two well written paragraphs. The first paragraph summarizes in your own words the article of "Oil Spill Impacts". The second paragraph provides your analysis that connects the...
-
In a recent Gallup poll, pollsters randomly selected adults and asked them whether they smoke. Among the adults who responded to the survey question, 21% said that they did smoke. Is that value of...
-
The 2004 Wells Report found which two measures to be more effective in preventing fraud?
-
Impairment Presented below is information related to equipment owned by Pujols Company at December 31, 2010. Cost $9,000,000 Accumulated depreciation to date 1,000,000 Expected future net cash flows...
-
On October 10, the stockholders?? equity section of ShermanSystems appears as follows.Common stock??$10 par value, 89,000 shares authorized, issued,and outstanding$ 890,000Paid-in capital 2 answers
-
FeVer Beverages is a typical coffee shop that operates at Batangas. Recently, the general manager is facing a challenge about not meeting their target lead time of serving the hot coffee of 15...
-
use the link to answer these questions https://phet.colorado.edu/sims/html/projectile-motion/latest/projectile-motion_en.html Activity 1 1. With the 'Vectors' area of the simulation open, click and...
-
Identify and describe the main criteria which should be met by a local area network design. What reasons would you put forward for adopting a database as a basis for an information system? It has...
-
1. Assume a scale shows the weight of a person at rest to be 600 N. The person takes the scale into an elevator and steps on it. What weight does the scale show while the person moves in the elevator...
-
The specific rotation of a drug with (S)-configuration is - 5.4. Determine the percent composition of a mixture of (R) and (S) carvone if the specific rotation of the mixture 2.50. (8 points). For...
-
In april of 1966, Chicago Club slugger Dave Kingman hit a home run which cleared the Wrigley Field Force fence and hit a house located 530 feet(162 m) from home plate. Suppose that the 0.146-kg...
-
Problem 1, 1D motion and vectors: An object is released from rest at a height h. During the final second of its fall, it traverses a distance of 38 m. Determine h. Choose a coordinate system with the...
-
Lonnie Davis has been a general partner in the Highland Partnership for many years and is also a sole proprietor in a separate business. To spend more time focusing on his sole proprietorship, he...
-
Let X be a random variable taking on values a1, a2, . . . , pr with probabilities p1, p2, . . . , pr and with E(X) = μ. Define the spread of X as follows: This, like the standard deviation, is a...
-
To test for equal variances for the whole- plot portion of the model in Question 15, calculate the aver-age for each whole- plot unit. In our study, the whole- plot unit is Subject. Thus, calculate...
-
Compare the sums of squares (SS) in Question 8 to those in Question 15. Since the data set is still based on the 48 test scores, the total SS stays the same. List which SS stayed the same and...
-
Use statistical software to calculate the F-statistic and find the p-value. Use the p-value to draw conclusions from this study.
-
Staples Corporation would have had identical income before taxes on both its income tax returns and its income statements for the years 2020 through 2023 except for a depreciable asset that cost \(\$...
-
Repeat the requirements of Exercise 18-44, but now assume that the asset was \(100 \%\) expensed for tax purposes in 2020. Exercise 18-44 Staples Corporation would have had identical income before...
-
For 2020, Trendy Inc. calculated taxable income of \(\$ 30,000\) after taking into account one temporary difference: prepaid insurance expense on a GAAP basis exceeds prepaid insurance on a tax basis...
Study smarter with the SolutionInn App