Argument does not support iteration. How to solve?

0

I'm trying to apply the zip to the x, y, and z lists, but when I run the program, I get the following error: izip argument # 1 must support iteration. Can anyone help me fix my error?

from matplotlib.backends.backend_qt4agg import FigureCanvasQTAgg as FigureCanvas
from matplotlib.figure import Figure 
from mpl_toolkits.mplot3d.art3d import Poly3DCollection
import numpy as np    
from matplotlib import pyplot as plt

fig = Figure((5.0, 5.0), dpi=80, tight_layout=True, frameon=False)  #linhas referentes a criação do canvas de plotagem
canvas = FigureCanvas(fig)
axes = fig.add_subplot(111, projection='3d')

xi = np.linspace(0., 9.0, 20)
yi = list(np.linspace(0., 7.0, 20))
zi = list(np.linspace(0., 2.0, 20))
yf = 2*xi -5
xi = list(xi)
yf = list(yf)
x = xi + xi
y = yi + yf
z = zi + zi
verts = list(zip(x, y, z))

axes.add_collection3d(Poly3DCollection(verts, facecolor = 'black', alpha=0.5 ), zs='z')  #plota figura
fig = plt.figure()
axes = fig.gca(projection='3d')
    
asked by anonymous 02.10.2018 / 23:19

0 answers