Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Dataset: Gapminder data Description: Excerpt of the Gapminder data on life expectancy, GDP per capita, and population by country. Variables: ( i ) Country (

Dataset: Gapminder data
Description: Excerpt of the Gapminder data on life expectancy, GDP per capita, and population by country.
Variables:
(i) Country
(ii) Continent
(iii)year: ranges from 1952 to 2007 in increments of 5 years
(iv) lifeExp: life expectancy at birth, in years
(v) pop: population
(vi) gdpPercap: GDP per capita (US$, inflation-adjusted)
1. Using the 'Gapminder' dataset, filter the data for the year 2007 and create a new variable 'gdp_category' based on GDP per capita. Classify countries into three categories: 'Low,' 'Medium,' and 'High' based on the following criteria:
'Low' if GDP per capita is less than 10000.
'Medium' if GDP per capita is between 10000(inclusive) and 20000(exclusive).
'High' if GDP per capita is 20000 or more.
Write a script to perform these operations and provide a brief explanation of your approach.
2. Using the filtered 'gapminder' dataset for the year 2007 and the previously created 'gdp_category' variable, conduct a detailed comparative analysis of life expectancy across different GDP categories. Hint: Only use appropriate graphics and/or descriptive statistics to help you achieve this.
3. Generate an appropriate plot to explore the evolution of life expectancy across any five selected countries, with each country representing one continent. Utilize the 'gapminder' dataset for this analysis. USING R STUDIO

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image_2

Step: 3

blur-text-image_3

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Database Processing Fundamentals, Design, and Implementation

Authors: David M. Kroenke, David J. Auer

14th edition

133876705, 9781292107639, 1292107634, 978-0133876703

More Books

Students also viewed these Databases questions