Name the outlier
You've identified that a company in the Industrial Technology sector has a P/E ratio of greater than 50. Let's identify this company.
numpy is imported as np, and arrays it_pe (P/E ratios of Industrial Technology companies) and it_names (names of Industrial Technology companies) are available in your workspace.
Deze oefening maakt deel uit van de cursus
Introduction to Python for Finance
Oefeninstructies
- Identify the P/E ratio greater than 50 and assign it to
outlier_price. - Identify the company with P/E ratio greater than 50 and assign it to
outlier_name.
Praktische interactieve oefening
Probeer deze oefening eens door deze voorbeeldcode in te vullen.
# Identify P/E ratio within it_pe that is > 50
outlier_price = it_pe[____ > 50]
# Identify the company with PE ratio > 50
outlier_name = it_names[____]
# Display results
print("In 2017, " + str(outlier_name[0]) + " had an abnormally high P/E ratio of " + str(round(outlier_price[0], 2)) + ".")