MCPcopy Create free account
hub / github.com/bsomps/OpenGeoPlotter / secondary_bar_plot

Method secondary_bar_plot

OGP_v11.py:1643–1657  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

1641
1642
1643 def secondary_bar_plot(self):
1644
1645 # Get a list of numerical columns
1646 numerical_columns = self.data.select_dtypes(include=[np.number]).columns.tolist()
1647 if not numerical_columns:
1648 QMessageBox.warning(self, "Warning", "No numerical columns found in the data.")
1649 return
1650
1651 # Create a dialog for the user to select a column
1652 column, ok = QInputDialog.getItem(self, "Select Column", "Choose a numerical column for the secondary bar plot:", numerical_columns, 0, False)
1653
1654 if ok and column:
1655 self.bar_column = column # Store the selected column as an instance variable
1656 self.plot() # Re-draw the plot
1657 self.canvas.draw()
1658
1659
1660 def plot_bars(self, bar_column, ax):

Callers

nothing calls this directly

Calls 1

plotMethod · 0.95

Tested by

no test coverage detected