5

I have a 2 part question:

what is the best method for plotting data in Python? I only need to plot data in 2d.

I have a canvas GUI that I built using Tkinter's canvas function. It draws an 8x8 grid of rectangles and also has some code to allow you to scroll the window. (I've attached a picture).

Is it possible to include a plot in the same window as this canvas object? I need to be able to display plotted data and hopefully add buttons to my GUI that will allow me to update the plot during the run of the GUI.

Thanks in advance!

enter image description here

1 Answer 1

2

Matplotlib is the de-facto way to plot data with Python. It's really wonderful. It can also be embedded in Tk.

Sign up to request clarification or add additional context in comments.

2 Comments

Can you plot with it in real time? Like with input being read from a file? Or changing features/options with GUI buttons?
Absolutely. You can even display animations. (It's a bit tricky, though) The documentation is pretty good. Take a look at the other user interface examples: matplotlib.sourceforge.net/examples/user_interfaces/index.html

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.