Answered step by step
Verified Expert Solution
Question
1 Approved Answer
Problem 3) top_2_2000s What were the two most commonly awarded levels of educational attainment awarded between 2000-2010 (inclusive)? Use the mean percent over the years
Problem 3) top_2_2000s What were the two most commonly awarded levels of educational attainment awarded between 2000-2010 (inclusive)? Use the mean percent over the years to compare the education levels. Call this method top_2_2000s and return a Series with the top two values (the index should be the degree names and the values should be the percent). For example, assuming we have parsed hw3-nces-ed-attainment.csv and stored it in a variable called data, then top_2_2000s (data) will return: Min degree high school 87.557143 associate's 38.757143 Name: Total, dtype: float64 Hint: The Series class also has a method nlargest that behaves similarly to the one for the DataFrame, but does not take a column parameter (as Series objects don't have columns). Our assert_equals only checks that floating point numbers are within 0.001 of each other, so your floats do not have to match exactly. Optional: Why 0.001? Problem 4) percent_change_bachelors_2000s What is the difference between total percent of bachelor's degrees received in 2000 as compared to 2010? Take a sex parameter so the client can specify 'M', 'F' or 'A' for evaluating. If a call does not specify the sex to evaluate, you should evaluate the percent change for all students (sex = 'A'). Call this method percent_change_bachelors_2000s and return the difference as a float. For example, assuming we have parsed hw3-nces-ed-attainment.csv and stored it in a variable called data , then the call percent_change_bachelors_2000s (data) will return 2.599999999999998 . Our assert_equals only checks that floating point numbers are within 0.001 of each other, so your floats do not have to match exactly. Problem 3) top_2_2000s What were the two most commonly awarded levels of educational attainment awarded between 2000-2010 (inclusive)? Use the mean percent over the years to compare the education levels. Call this method top_2_2000s and return a Series with the top two values (the index should be the degree names and the values should be the percent). For example, assuming we have parsed hw3-nces-ed-attainment.csv and stored it in a variable called data, then top_2_2000s (data) will return: Min degree high school 87.557143 associate's 38.757143 Name: Total, dtype: float64 Hint: The Series class also has a method nlargest that behaves similarly to the one for the DataFrame, but does not take a column parameter (as Series objects don't have columns). Our assert_equals only checks that floating point numbers are within 0.001 of each other, so your floats do not have to match exactly. Optional: Why 0.001? Problem 4) percent_change_bachelors_2000s What is the difference between total percent of bachelor's degrees received in 2000 as compared to 2010? Take a sex parameter so the client can specify 'M', 'F' or 'A' for evaluating. If a call does not specify the sex to evaluate, you should evaluate the percent change for all students (sex = 'A'). Call this method percent_change_bachelors_2000s and return the difference as a float. For example, assuming we have parsed hw3-nces-ed-attainment.csv and stored it in a variable called data , then the call percent_change_bachelors_2000s (data) will return 2.599999999999998 . Our assert_equals only checks that floating point numbers are within 0.001 of each other, so your floats do not have to match exactly
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started