Post Reply 
Python: How to Show a Plot
05-09-2021, 08:28 PM
Post: #2
RE: Python: How to Show a Plot
(05-09-2021 06:29 PM)Eddie W. Shore Wrote:  This is what I have so far:

Code:
from matplol import *
# scatter plot
axis((0,0,10,10))
grid(True)
plot(1,1)
xlist=[1,2,3,4,5]
ylist=[7,8,9,8,7]
show()

Nothing is shown.

Software Version 5/5/2021 (2.1.14588) - Hardware Version D

Hi Eddie, a couple of things:
  • matplotl is misspelled in your code
  • from your code, the only thing I see plotted is a point plot(1,1), are you trying to plot xlist and ylist?
  • it seems grid and axis are not yet working--also, I believe the syntax for axis is axis([0, 10, 0, 10])
Find all posts by this user
Quote this message in a reply
Post Reply 


Messages In This Thread
RE: Python: How to Show a Plot - ace - 05-09-2021 08:28 PM
RE: Python: How to Show a Plot - rprosperi - 05-09-2021, 11:43 PM
RE: Python: How to Show a Plot - tcab - 05-09-2021, 11:43 PM
RE: Python: How to Show a Plot - ace - 05-10-2021, 05:35 AM
RE: Python: How to Show a Plot - robmio - 05-10-2021, 07:34 PM



User(s) browsing this thread: 2 Guest(s)