Part 1 - Binning by Size: Make a bar graph of the five bins and label properly.

You are going to categorize the exoplanets into five bins: 'smaller than Mars', 'smaller than

Earth', 'Super Earth Size (1-2 times Earth Size)', 'smaller than Saturn', 'greater than Saturn'. You

may not use an if statments or loops, use only array operations. After determining how many

planets satisfy each of the five conditions, you will store those quanties in each of the five

elements of the arrays with variable name 'bin'. Your bar graph should look like this (this was

done with inclusive condition at the max end of the range, and exclusive conditions at the min

end of each range, i.e. "smaller than or equal to mars', ' larger than mars and smaller than or

equal to earth', etc.):

1200

Exoplanets Binned by Size

1090

400

200

Part 2 - Finding Habitable Exoplanets

You are going to find the all the "potentially habitable exoplanets'. An exoplanet is habitable

when all of these conditions are true:

Planet radius is greater than 0.4 and less than 2.5

Planet's orbit is between 91 and 801 days (exclusive, like above)

Planet's equilibrium temperature is between 187 and 294 Kelvin (exclusive)

Distance from planet to its sun is between 0.75 and 1.84 AU (exclusive; 1 solar radius

= 1/215 AU)

You should locate and save the positions that satisfy the above criteria (save to variable name

'ind habit"). Then, save the names of the exoplanets associated with those index locations to the

variable 'habit_pl'. Use this variable exactly (and the rest of the variables exactly), as it will be

checked it in the tests below. Print the results to the screen (it is easiest to do this with two

separate disp calls):

These exoplanets are within the habitable zone:

"Kepler-22"

"Kepler-452"

"Kepler-62"

Part 3 - Remove NaNs and Sort by size

You are gong to sort the planets by size in order of smallest to largest.

a. Remove NaNs - you will notice that some values in the rad array are filled with NaN instead

of a value. This is becuase some explanets do not have data for their radius. The first step of

this part is to remove all the data (rad and names_pl) that do not have available radius data.

(HINT: There is a built in function called isnan that you will need to use for this part). Save

indices of where the NaNs are located to the variable name 'ind nan'

b. Sort the planets by size - The final step of this part is to sort the planets by their size from

smallest to largest. You must sort only the data without the NaNs in, so make sure remove them

first (part a). Then you will use the built in function (sort) to sort from smallest to largest (save

the sorted radii to array with variable name 'rad s'). You will need to look at the help to

understand fully how to use the built-in funciton. Save the indices of the sort to the array with

variable name 'ind_s' Save the names in sorted order to the variable 'names_pl_s'. Once you

have sorted, print out the top five smallest planets like this (it is easiest to do this with two

separate disp calls):

Top five smallest exoplanets:

"Kepler-37"

"Kepler-444"

"Kepler-102"

"Kepler-444"

"Kepler-1308"