Gráficos básicos com a Matplotlib

Python intermediário

Hugo Bowne-Anderson

Data Scientist at DataCamp

Gráficos básicos com a Matplotlib

  • Visualização

ícone de gráfico de barras

  • Estrutura de dados

ícone de código

  • Estruturas de controle

  • Estudo de caso:

Python intermediário

Visualização de dados

  • Muito importante na análise de dados

    • Explore os dados
    • Relatório de insights

Python intermediário

1 Fonte: GapMinder, Wealth and Health of Nations
Python intermediário

1 Fonte: GapMinder, Wealth and Health of Nations
Python intermediário

1 Fonte: GapMinder, Wealth and Health of Nations
Python intermediário

Matplotlib

import matplotlib.pyplot as plt

year = [1950, 1970, 1990, 2010]
pop = [2.519, 3.692, 5.263, 6.972]
plt.plot(year, pop)
plt.show()

Python intermediário

Matplotlib

Python intermediário

Matplotlib

Python intermediário

Gráfico de dispersão

import matplotlib.pyplot as plt
year = [1950, 1970, 1990, 2010]
pop = [2.519, 3.692, 5.263, 6.972]
plt.plot(year, pop)
plt.show()
Python intermediário

Gráfico de dispersão

import matplotlib.pyplot as plt
year = [1950, 1970, 1990, 2010]
pop = [2.519, 3.692, 5.263, 6.972]
plt.scatter(year, pop)
plt.show()

Python intermediário

Vamos praticar!

Python intermediário

Preparing Video For Download...