Plotting a PANDAS DF to a 3D line-graph with changing width
Plotting a PANDAS DF to a 3D line-graph with changing width I have a PANDAS DataFrame with the following data: DF0 = pd.DataFrame(np.random.uniform(0,100,(4,2)), columns=['x', 'y']) pupil_rads = pd.Series(np.random.randint(1,10,(4))) DF0["pupil_radius"] = pupil_rads DF0 [out:] x y pupil_radius 0 20.516882 15.098594 8 1 92.111798 97.200075 2 2 98.648040 94.133676 3 3 8.524813 88.978467 7 I want to create a 3D graph, showing where the gaze was pointed at (x/y coordinates) in every measurement (index of the DF). Also, I'm trying to make it a line-graph so that the radius of the line would correspond with the pupil-radius. So far what I've come up with is the following: gph = plt.figure(figsize=(15,8)).gca(projection='3d') gph.scatter(DF0.index, DF0['x'], DF0['y']) gph.set_xlabel('Time Stamp') gph.set_ylabel('X_Gaze') gph.set_zlabel('Y_Gaze') This creates...