# gapminder import plotly_express as px import pandas as pd pd.plotting.register_matplotlib_converters() import matplotlib.pyplot as plt %matplotlib inline import seaborn as sns import numpy as np
# gapminderimportplotly_expressaspximportpandasaspdpd.plotting.register_matplotlib_converters()importmatplotlib.pyplotasplt%matplotlibinlineimportseabornassnsimportnumpyasnpfromgapminderimportgapmindergapminder.head()#scatterfig = px.scatter(gapminder,x="Income",y="Life Expectancy",size="Population",size_max=60,color="Region",hover_name="Country",facet_col="Income Level",color_discrete_sequence=["#FF69B4","#87CEFA","#FFFF00","#32CD32"],range_y=[50, 90],width=1000,labels={"Income": "Incomein$s", "LifeExpectancy": "LifeExpectancyinyears"},title="World Map for Health and Wealth (data from 2018)",opacity=1 )fig.layout.xaxis1.update(matches=None)fig.layout.xaxis2.update(matches=None)fig.layout.xaxis3.update(matches=None)fig.layout.xaxis4.update(matches=None)py.iplot(fig,sharing='public',filename='factfulness_bubble_chart_2018')p.head()