2014-2015/T_STMG/DM/DM_mathmana/vente_prod.py
2017-06-16 09:48:07 +03:00

82 lines
1.3 KiB
Python

# coding: utf-8
import pandas as pd
ventes = pd.read_excel("./ventes.xls")
ventes = pd.read_excel("./ventes.xls", "Feuille1")
ventes
L = []
for i in ventes:
L += [i['Tailles']] * i['effectifs]
for i in ventes:
L += [i['Tailles']] * i['effectifs']
for i in ventes:
print(i)
for i in ventes.iteritems():
print(i)
for i in ventes.items():
print(i)
for i in ventes.index():
print(i)
for i in ventes.index:
print(i)
for i in ventes.index:
print(ventes[i])
ventes
ventes = ventes.set_index('Taille')
ventes = ventes.set_index(ventes['Taille'])
ventes
ventes = ventes.set_index('Tailles')
ventes
for i in ventes:
print(i)
for i in ventes.items:
print(i)
for i in ventes.items():
print(i)
ventes = pd.read_excel("./ventes.xls", "Feuille1")
ventes.transpose()
ventes = ventes.transpose()
ventes
ventes.describe()
for i in ventes:
print(i)
for i in ventes:
print(ventes[i])
for i in ventes:
print(ventes[i][0])
L = []
for i in ventes:
L += [ventes[i][0]] * ventes[i][1]
L
L = pd.Series(L)
L
L.describe
L.describe()
prod = pd.read_excel("./production.xls", "Feuille1")
prod
prod = prod.transpose()
prod
P = []
for i in prod:
P += [prod[i][0]] * prod[i][1]
P
P = pd.Series(P)
P
P.describe()
get_ipython().magic('save vente_prod 1-48')