python

python


ubungen


escribir una serie de pandas, con las notas de los alumnos

y devuelva un diagrama con las notas

..el diagrama debe tener 

propuesta invitado

php>

for a =  n +1


print   " Distribucion de notas  "

?>



respuesta - solucion-

---------------------------------------------------------------------------

import pandas  ad pds

import matplot podis

def diagramas_caja-notas( notas ) :


parametros:


fig,ax = plt.subplots( )

# dibujamos 

notas.plot( kind= ' box', ax = ax )


# eliminamos las marcas del eje x

plt.xticks ( [  ] )

plt.title (  'distribucio de notas'    )

return ax

notas= [  4,8 , 7.5 , 6 , 5.5 , 5.2 , 3,5 , 7.7      ]

S_Notas =pd.series ( notas )

diagrama_caja_notas(s_notas)

plt.show( )

---------------------------------------

0 CLP