mardi 23 juin 2020

Select and plot lists through checkbuttons (python, tkinter)

Say I got a multidimensional list:

my_list = [[1,2,3,4,5], [2,3,4,5,6], [3,4,5,6,7]]

Now I want to create a GUI with Tkinter where one could check boxes to select which of these sub-lists should be plotted in a histogram. So for this example I imagine three checkboxes (labeled 0, 1, 2) and a Button "Show Histograms". Say I check boxes labeled 1 and 2 and press the "Show Histograms" Button, it should show the histograms of my_list[0]and my_list[1](preferably as subplots on one canvas). What would be the approach?




Aucun commentaire:

Enregistrer un commentaire