Python - Barras horizontales de color

 
Vista:

Barras horizontales de color

Publicado por Geomata (21 intervenciones) el 12/01/2021 10:00:46
1
2
3
4
5
6
7
8
9
10
11
12
13
14
plt.matshow(g,cmap='gray')
plt.matshow(k,cmap='gray')
l=np.ones((30,150))
plt.matshow(l,cmap='gray')
m=np.zeros((30,150))
n=np.block([[l],[l],[m],[l],[m]])
plt.matshow(n,cmap='gray')
o=np.block([[m],[l],[l],[l],[m]])
green=o*255
red=n*255
p=np.block([[m],[l],[m],[l],[l]])
blue=p*255
bandera=np.dstack([red,green,blue])
plt.imshow (bandera)
Valora esta pregunta
Me gusta: Está pregunta es útil y esta claraNo me gusta: Está pregunta no esta clara o no es útil
0
Responder