Question: Question 7 . 3 . Create a new DataFrame, called disney, by setting the index of disney _ movies to 'movie _ title'. Don't change

Question 7.3. Create a new DataFrame, called disney, by setting the index of disney_movies to 'movie_title'. Don't change disney_movies.
disney = disney_movies.set_index('movie_title')
disney
genre MPAA_rating year total_gross_millions adjusted_gross_millions
movie_title
Snow White and the Seven Dwarfs Musical G 1937184.9254855228.953251
Pinocchio Adventure G 194084.3000002188.229052
Fantasia Musical G 194083.3200002187.090808
Song of the South Adventure G 194665.0000001078.510579
Cinderella (1950) Drama G 195085.000000920.608730
..................
The Light Between Oceans Drama PG-13201612.54597912.545979
Queen of Katwe Drama PG 20168.8743898.874389
Doctor Strange Adventure PG-132016232.532923232.532923
Moana Adventure PG 2016246.082029246.082029
Rogue One: A Star Wars Story Adventure PG-132016529.483936529.483936
579 rows \times 5 columns
grader.check("q7_3")
q7_3 passed!
You should think about why we've chosen to set the index to 'movie_title', instead of any other column.
Question 7.4. Time for some movie trivia! What genre is the movie 'Finding Nemo' and in what year was it released? Assign your answers to nemo_genre, which should be a string, and nemo_year, which should be an int.
Don't type in the answers by hand; get Python to extract this information for you.
year
nemo_genre = disney.get('genre').loc['Finding Nemo']
nemo_year = disney.get('year').loc['Finding Nemo']
# Don't change the lines below.
print('Genre', nemo_genre)
print('Year:', nemo_year)
Genre Adventure
Year: 2003
grader.check("q7_4")
q7_4 passed!
Question 7.5. Disney has produced many successful films over the years. Find the number of movies with an adjusted box office revenue of over 100 million dollars. Assign your answer to disney_100m.

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!