SlideShare a Scribd company logo
1 of 6
Download to read offline
Introducción a Python
Ing. Ernesto Freyre G.
Clase 10: Matplotlib
Objetivos Clase 10
-Matplotlib
1. Arreglo
2. Operaciones basicas
3. Indexacion, Iteracion, Particionado
4. Matrices
Matplotlib
- Libreria de generacion de graficos a partir de listas
de Python o arreglos Numpy
- Incluye “pylab”, creada para asemejar MATLAB
import numpy as np!
import matplotlib.pyplot as plt!
x = np.linspace(0,2*np.pi,100)!
y = np.sin(x)!
plt.plot(x,y)!
plt.ylabel('SIN')!
plt.xlabel('RADIANS')!
plt.show()
plot
- Recibe varios grupos de parametros indicando las
series de datos x, y que se van a graficar.
- Un tercer parametro opcional indica la forma de
representar visualmente esos datos (Siguiendo el
mismo formato de MATLAB)
x = np.arange(0,0.3,0.01)!
!
plt.plot(x,x,‘r--’, x,x**2,’bs’, x,x***3,’g^’)!
plt.show()
plot
- .axis( [xmin, xmax, ymin, ymax] ) Especifica el area
de vision de la grafica
'-' 	 solid line style
'--' 	 dashed line style
'-.' 	 dash-dot line style
':' 	 dotted line style
'.' 	 point marker
',' 	 pixel marker
'o' 	 circle marker
'v' 	 triangle_down marker
'^' 	 triangle_up marker
'<' 	 triangle_left marker
'>' 	 triangle_right marker
'1' 	 tri_down marker
'2' 	 tri_up marker
'3' 	 tri_left marker
'4' 	 tri_right marker
's' 	 square marker
'p' 	 pentagon marker
'*' 	 star marker
'h' 	 hexagon1 marker
'H' 	 hexagon2 marker
'+' 	 plus marker
'x' 	 x marker
'D' 	 diamond marker
'd' 	 thin_diamond marker
'|' 	 vline marker
'_' 	 hline marker
‘b’ 	 blue
‘g’ 	 green
‘r’ 	 red
‘c’ 	 cyan
‘m’ 	 magenta
‘y’ 	 yellow
‘k’ 	 black
‘w’ 	 white
Estilos de Puntos y Lineas Colores
Otros tipos de Graficas
- Histogramas “hist(x)”
- Poligonos: “fill”
- Diferencia de Poligonos: “fill_between”

More Related Content

What's hot

Práctica 5 matlab 23_noviembre_2017
Práctica 5 matlab 23_noviembre_2017Práctica 5 matlab 23_noviembre_2017
Práctica 5 matlab 23_noviembre_2017Mafer Pinto
 
Summer school python in spanish
Summer school python in spanishSummer school python in spanish
Summer school python in spanishAjay Ohri
 
Manual aplicacion libre 1
Manual aplicacion libre 1Manual aplicacion libre 1
Manual aplicacion libre 1juancho1554
 
Comandos para la generación de datos que utilizan la simulación
Comandos para la generación de datos que utilizan la simulaciónComandos para la generación de datos que utilizan la simulación
Comandos para la generación de datos que utilizan la simulaciónVIKMAN Penagos
 
Introduccion a Python y Data Science
Introduccion a Python y Data ScienceIntroduccion a Python y Data Science
Introduccion a Python y Data ScienceGustavo Andres Brey
 
CLASES STRING MATH TIME
CLASES STRING MATH TIMECLASES STRING MATH TIME
CLASES STRING MATH TIMEFernando Solis
 
Taller de derivadas
Taller de derivadasTaller de derivadas
Taller de derivadasLenin Castro
 
Memoria dinamica
Memoria dinamicaMemoria dinamica
Memoria dinamicagusolis93
 
Resolucion de un circuito lrc
Resolucion de un circuito lrcResolucion de un circuito lrc
Resolucion de un circuito lrcStalin Amaya
 
Unidad dos, estructura de datos
Unidad dos, estructura de datosUnidad dos, estructura de datos
Unidad dos, estructura de datosRené Sosa Arana
 
MATLAB Marzo - Examen
MATLAB Marzo - ExamenMATLAB Marzo - Examen
MATLAB Marzo - ExamenJose Cordova
 

What's hot (20)

Práctica 5 matlab 23_noviembre_2017
Práctica 5 matlab 23_noviembre_2017Práctica 5 matlab 23_noviembre_2017
Práctica 5 matlab 23_noviembre_2017
 
Practica 1
Practica 1Practica 1
Practica 1
 
Summer school python in spanish
Summer school python in spanishSummer school python in spanish
Summer school python in spanish
 
4 memoria dinamica
4 memoria dinamica4 memoria dinamica
4 memoria dinamica
 
Manual aplicacion libre 1
Manual aplicacion libre 1Manual aplicacion libre 1
Manual aplicacion libre 1
 
Comandos para la generación de datos que utilizan la simulación
Comandos para la generación de datos que utilizan la simulaciónComandos para la generación de datos que utilizan la simulación
Comandos para la generación de datos que utilizan la simulación
 
Introduccion a Python y Data Science
Introduccion a Python y Data ScienceIntroduccion a Python y Data Science
Introduccion a Python y Data Science
 
CLASES STRING MATH TIME
CLASES STRING MATH TIMECLASES STRING MATH TIME
CLASES STRING MATH TIME
 
Python para principiantes
Python para principiantesPython para principiantes
Python para principiantes
 
Eplicacion triqui
Eplicacion triquiEplicacion triqui
Eplicacion triqui
 
Memoria memoria dinamica
 Memoria memoria dinamica Memoria memoria dinamica
Memoria memoria dinamica
 
Taller de derivadas
Taller de derivadasTaller de derivadas
Taller de derivadas
 
Memoria dinamica
Memoria dinamicaMemoria dinamica
Memoria dinamica
 
Ejercicios resueltos con Python
Ejercicios resueltos con PythonEjercicios resueltos con Python
Ejercicios resueltos con Python
 
Mathscript
MathscriptMathscript
Mathscript
 
Clase2_Python-CTIC
Clase2_Python-CTICClase2_Python-CTIC
Clase2_Python-CTIC
 
Resolucion de un circuito lrc
Resolucion de un circuito lrcResolucion de un circuito lrc
Resolucion de un circuito lrc
 
Unidad dos, estructura de datos
Unidad dos, estructura de datosUnidad dos, estructura de datos
Unidad dos, estructura de datos
 
MATLAB Marzo - Examen
MATLAB Marzo - ExamenMATLAB Marzo - Examen
MATLAB Marzo - Examen
 
Practica 2
Practica 2Practica 2
Practica 2
 

Viewers also liked

С днём рождения!
С днём рождения!С днём рождения!
С днём рождения!TheShkola21
 
Exploratory tour of usawww.Tripmart.com
Exploratory tour of usawww.Tripmart.comExploratory tour of usawww.Tripmart.com
Exploratory tour of usawww.Tripmart.comtripmart
 
Otts brand 03 15
Otts brand 03 15Otts brand 03 15
Otts brand 03 15Nick Cole
 
Introduction to chinese
Introduction to chineseIntroduction to chinese
Introduction to chinesebenjaviv
 
Webinar: Increase research efficiency and enable collaboration with the IDBS ...
Webinar: Increase research efficiency and enable collaboration with the IDBS ...Webinar: Increase research efficiency and enable collaboration with the IDBS ...
Webinar: Increase research efficiency and enable collaboration with the IDBS ...IDBS
 
5S Lilly Civilization
5S Lilly Civilization5S Lilly Civilization
5S Lilly CivilizationgsbSS
 
Course 2 week 6 lesson 10
Course 2 week 6 lesson 10Course 2 week 6 lesson 10
Course 2 week 6 lesson 10Joe Mellin
 
с днём рождения!
с днём рождения!с днём рождения!
с днём рождения!TheShkola21
 
Absensi peserta tdo
Absensi peserta tdoAbsensi peserta tdo
Absensi peserta tdotgk.anas
 
Informe consulta general
Informe consulta generalInforme consulta general
Informe consulta generalangiedaiana
 

Viewers also liked (20)

С днём рождения!
С днём рождения!С днём рождения!
С днём рождения!
 
Lachlan - LTS12
Lachlan - LTS12Lachlan - LTS12
Lachlan - LTS12
 
kitai
kitaikitai
kitai
 
FF - Buyers Guidex4
FF - Buyers Guidex4FF - Buyers Guidex4
FF - Buyers Guidex4
 
Exploratory tour of usawww.Tripmart.com
Exploratory tour of usawww.Tripmart.comExploratory tour of usawww.Tripmart.com
Exploratory tour of usawww.Tripmart.com
 
1 intro
1 intro1 intro
1 intro
 
Otts brand 03 15
Otts brand 03 15Otts brand 03 15
Otts brand 03 15
 
Introduction to chinese
Introduction to chineseIntroduction to chinese
Introduction to chinese
 
John institution q
John institution qJohn institution q
John institution q
 
Webinar: Increase research efficiency and enable collaboration with the IDBS ...
Webinar: Increase research efficiency and enable collaboration with the IDBS ...Webinar: Increase research efficiency and enable collaboration with the IDBS ...
Webinar: Increase research efficiency and enable collaboration with the IDBS ...
 
5S Lilly Civilization
5S Lilly Civilization5S Lilly Civilization
5S Lilly Civilization
 
Huldy orjuela
Huldy orjuelaHuldy orjuela
Huldy orjuela
 
Amrita Senger
Amrita SengerAmrita Senger
Amrita Senger
 
Course 2 week 6 lesson 10
Course 2 week 6 lesson 10Course 2 week 6 lesson 10
Course 2 week 6 lesson 10
 
с днём рождения!
с днём рождения!с днём рождения!
с днём рождения!
 
Absensi peserta tdo
Absensi peserta tdoAbsensi peserta tdo
Absensi peserta tdo
 
Informe consulta general
Informe consulta generalInforme consulta general
Informe consulta general
 
Evaluation 1 mg
Evaluation 1 mgEvaluation 1 mg
Evaluation 1 mg
 
Exam 3eso 1aval
Exam 3eso 1avalExam 3eso 1aval
Exam 3eso 1aval
 
Essay ekopol
Essay ekopolEssay ekopol
Essay ekopol
 

Similar to Introducción a Matplotlib en Python

Metodologia para resolver problemas con Programacion orientada a Objetos
Metodologia para resolver problemas con Programacion orientada a ObjetosMetodologia para resolver problemas con Programacion orientada a Objetos
Metodologia para resolver problemas con Programacion orientada a ObjetosWilliam Diaz S
 
Sesion1_Ciencia_de_Datos-Introduccion a Pithon.pdf
Sesion1_Ciencia_de_Datos-Introduccion a Pithon.pdfSesion1_Ciencia_de_Datos-Introduccion a Pithon.pdf
Sesion1_Ciencia_de_Datos-Introduccion a Pithon.pdfMarxx4
 
Red neuronal recurrente
Red neuronal recurrenteRed neuronal recurrente
Red neuronal recurrenteMichel Jraiche
 
redes neuronales patrones
redes neuronales patronesredes neuronales patrones
redes neuronales patronesMarc Llanos
 
Utp ia_sl2 patrones de aprendizaje de las rna
 Utp ia_sl2 patrones de aprendizaje de las rna Utp ia_sl2 patrones de aprendizaje de las rna
Utp ia_sl2 patrones de aprendizaje de las rnajcbenitezp
 
Matlab (1)
Matlab (1)Matlab (1)
Matlab (1)numpad
 
Matlab
MatlabMatlab
Matlabford81
 
Computacion aplicada
Computacion aplicadaComputacion aplicada
Computacion aplicadaCarobrigit
 
Graficos en matlab
Graficos en matlabGraficos en matlab
Graficos en matlabMarc Llanos
 
9. listas y for-in
9.  listas y for-in9.  listas y for-in
9. listas y for-inFaby Ignacio
 

Similar to Introducción a Matplotlib en Python (20)

python CIENTIFIFO.pdf
python CIENTIFIFO.pdfpython CIENTIFIFO.pdf
python CIENTIFIFO.pdf
 
[Sesion03] introduccion python
[Sesion03] introduccion python[Sesion03] introduccion python
[Sesion03] introduccion python
 
Metodologia para resolver problemas con Programacion orientada a Objetos
Metodologia para resolver problemas con Programacion orientada a ObjetosMetodologia para resolver problemas con Programacion orientada a Objetos
Metodologia para resolver problemas con Programacion orientada a Objetos
 
Introduccion a Python. Clase 9
Introduccion a Python. Clase 9Introduccion a Python. Clase 9
Introduccion a Python. Clase 9
 
matlab
matlabmatlab
matlab
 
Sesion1_Ciencia_de_Datos-Introduccion a Pithon.pdf
Sesion1_Ciencia_de_Datos-Introduccion a Pithon.pdfSesion1_Ciencia_de_Datos-Introduccion a Pithon.pdf
Sesion1_Ciencia_de_Datos-Introduccion a Pithon.pdf
 
Red neuronal recurrente
Red neuronal recurrenteRed neuronal recurrente
Red neuronal recurrente
 
redes neuronales patrones
redes neuronales patronesredes neuronales patrones
redes neuronales patrones
 
Intro MatLab
Intro MatLabIntro MatLab
Intro MatLab
 
02 introduccion a python
02 introduccion a python02 introduccion a python
02 introduccion a python
 
Matlab
MatlabMatlab
Matlab
 
Python03
Python03Python03
Python03
 
Introducción Mathploit.docx
Introducción Mathploit.docxIntroducción Mathploit.docx
Introducción Mathploit.docx
 
Utp ia_sl2 patrones de aprendizaje de las rna
 Utp ia_sl2 patrones de aprendizaje de las rna Utp ia_sl2 patrones de aprendizaje de las rna
Utp ia_sl2 patrones de aprendizaje de las rna
 
Matlab (1)
Matlab (1)Matlab (1)
Matlab (1)
 
Matlab
MatlabMatlab
Matlab
 
Computacion aplicada
Computacion aplicadaComputacion aplicada
Computacion aplicada
 
Numpy y Scipy
Numpy y ScipyNumpy y Scipy
Numpy y Scipy
 
Graficos en matlab
Graficos en matlabGraficos en matlab
Graficos en matlab
 
9. listas y for-in
9.  listas y for-in9.  listas y for-in
9. listas y for-in
 

More from Ernesto Freyre Gonzalez

More from Ernesto Freyre Gonzalez (9)

Introduccion a Python. Clase 2
Introduccion a Python. Clase 2Introduccion a Python. Clase 2
Introduccion a Python. Clase 2
 
Introduccion a Python. Clase 3
Introduccion a Python. Clase 3Introduccion a Python. Clase 3
Introduccion a Python. Clase 3
 
Introduccion a Python. Clase 4
Introduccion a Python. Clase 4Introduccion a Python. Clase 4
Introduccion a Python. Clase 4
 
Introduccion a Python. Clase 5
Introduccion a Python. Clase 5Introduccion a Python. Clase 5
Introduccion a Python. Clase 5
 
Introduccion a Python. Clase 7
Introduccion a Python. Clase 7Introduccion a Python. Clase 7
Introduccion a Python. Clase 7
 
Introduccion a Python. Clase 1
Introduccion a Python. Clase 1Introduccion a Python. Clase 1
Introduccion a Python. Clase 1
 
Bluetooth Low Energy y Moviles
Bluetooth Low Energy y MovilesBluetooth Low Energy y Moviles
Bluetooth Low Energy y Moviles
 
Presentación ACADEMIC-OK
Presentación ACADEMIC-OKPresentación ACADEMIC-OK
Presentación ACADEMIC-OK
 
Clase 1 Programacion Android
Clase 1 Programacion AndroidClase 1 Programacion Android
Clase 1 Programacion Android
 

Recently uploaded

MacOS SISTEMA OPERATIVO CARACTERISTICAS.pptx
MacOS SISTEMA OPERATIVO CARACTERISTICAS.pptxMacOS SISTEMA OPERATIVO CARACTERISTICAS.pptx
MacOS SISTEMA OPERATIVO CARACTERISTICAS.pptxcalzadillasluis134
 
Se realiza instalacion y configuraacion servicios Windows
Se realiza instalacion y configuraacion servicios WindowsSe realiza instalacion y configuraacion servicios Windows
Se realiza instalacion y configuraacion servicios WindowsCZSOTEC
 
Webinar Resolucion2335 de 2023 Kubapp.pdf
Webinar Resolucion2335 de 2023 Kubapp.pdfWebinar Resolucion2335 de 2023 Kubapp.pdf
Webinar Resolucion2335 de 2023 Kubapp.pdfAnaRosaMontenegro
 
Delitos informáticos en Slideshare.pptx
Delitos informáticos en  Slideshare.pptxDelitos informáticos en  Slideshare.pptx
Delitos informáticos en Slideshare.pptxmaykolmagallanes012
 
Instalacion de servicios windows, configuracion y aplicacion.
Instalacion de servicios windows, configuracion y aplicacion.Instalacion de servicios windows, configuracion y aplicacion.
Instalacion de servicios windows, configuracion y aplicacion.CZSOTEC
 
SISTEMA INTEGRADO DE ADMINISTRACION FINANCIERA - SIAF MODULO ADMINISTRATIVO
SISTEMA INTEGRADO DE ADMINISTRACION FINANCIERA - SIAF MODULO ADMINISTRATIVOSISTEMA INTEGRADO DE ADMINISTRACION FINANCIERA - SIAF MODULO ADMINISTRATIVO
SISTEMA INTEGRADO DE ADMINISTRACION FINANCIERA - SIAF MODULO ADMINISTRATIVOELIAMARYTOVARFLOREZD
 
SQL server Analysis Services & SQL Server Reporting Services.pptx
SQL server Analysis Services & SQL Server Reporting Services.pptxSQL server Analysis Services & SQL Server Reporting Services.pptx
SQL server Analysis Services & SQL Server Reporting Services.pptxRAMIROANTONIOGALINDO
 

Recently uploaded (7)

MacOS SISTEMA OPERATIVO CARACTERISTICAS.pptx
MacOS SISTEMA OPERATIVO CARACTERISTICAS.pptxMacOS SISTEMA OPERATIVO CARACTERISTICAS.pptx
MacOS SISTEMA OPERATIVO CARACTERISTICAS.pptx
 
Se realiza instalacion y configuraacion servicios Windows
Se realiza instalacion y configuraacion servicios WindowsSe realiza instalacion y configuraacion servicios Windows
Se realiza instalacion y configuraacion servicios Windows
 
Webinar Resolucion2335 de 2023 Kubapp.pdf
Webinar Resolucion2335 de 2023 Kubapp.pdfWebinar Resolucion2335 de 2023 Kubapp.pdf
Webinar Resolucion2335 de 2023 Kubapp.pdf
 
Delitos informáticos en Slideshare.pptx
Delitos informáticos en  Slideshare.pptxDelitos informáticos en  Slideshare.pptx
Delitos informáticos en Slideshare.pptx
 
Instalacion de servicios windows, configuracion y aplicacion.
Instalacion de servicios windows, configuracion y aplicacion.Instalacion de servicios windows, configuracion y aplicacion.
Instalacion de servicios windows, configuracion y aplicacion.
 
SISTEMA INTEGRADO DE ADMINISTRACION FINANCIERA - SIAF MODULO ADMINISTRATIVO
SISTEMA INTEGRADO DE ADMINISTRACION FINANCIERA - SIAF MODULO ADMINISTRATIVOSISTEMA INTEGRADO DE ADMINISTRACION FINANCIERA - SIAF MODULO ADMINISTRATIVO
SISTEMA INTEGRADO DE ADMINISTRACION FINANCIERA - SIAF MODULO ADMINISTRATIVO
 
SQL server Analysis Services & SQL Server Reporting Services.pptx
SQL server Analysis Services & SQL Server Reporting Services.pptxSQL server Analysis Services & SQL Server Reporting Services.pptx
SQL server Analysis Services & SQL Server Reporting Services.pptx
 

Introducción a Matplotlib en Python

  • 1. Introducción a Python Ing. Ernesto Freyre G. Clase 10: Matplotlib
  • 2. Objetivos Clase 10 -Matplotlib 1. Arreglo 2. Operaciones basicas 3. Indexacion, Iteracion, Particionado 4. Matrices
  • 3. Matplotlib - Libreria de generacion de graficos a partir de listas de Python o arreglos Numpy - Incluye “pylab”, creada para asemejar MATLAB import numpy as np! import matplotlib.pyplot as plt! x = np.linspace(0,2*np.pi,100)! y = np.sin(x)! plt.plot(x,y)! plt.ylabel('SIN')! plt.xlabel('RADIANS')! plt.show()
  • 4. plot - Recibe varios grupos de parametros indicando las series de datos x, y que se van a graficar. - Un tercer parametro opcional indica la forma de representar visualmente esos datos (Siguiendo el mismo formato de MATLAB) x = np.arange(0,0.3,0.01)! ! plt.plot(x,x,‘r--’, x,x**2,’bs’, x,x***3,’g^’)! plt.show()
  • 5. plot - .axis( [xmin, xmax, ymin, ymax] ) Especifica el area de vision de la grafica '-' solid line style '--' dashed line style '-.' dash-dot line style ':' dotted line style '.' point marker ',' pixel marker 'o' circle marker 'v' triangle_down marker '^' triangle_up marker '<' triangle_left marker '>' triangle_right marker '1' tri_down marker '2' tri_up marker '3' tri_left marker '4' tri_right marker 's' square marker 'p' pentagon marker '*' star marker 'h' hexagon1 marker 'H' hexagon2 marker '+' plus marker 'x' x marker 'D' diamond marker 'd' thin_diamond marker '|' vline marker '_' hline marker ‘b’ blue ‘g’ green ‘r’ red ‘c’ cyan ‘m’ magenta ‘y’ yellow ‘k’ black ‘w’ white Estilos de Puntos y Lineas Colores
  • 6. Otros tipos de Graficas - Histogramas “hist(x)” - Poligonos: “fill” - Diferencia de Poligonos: “fill_between”