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

Method determine_plot_style

OGP_v11.py:1783–1799  ·  view source on GitHub ↗
(self, current_value, hole_data, i, cmap, norm)

Source from the content-addressed store, hash-verified

1781
1782
1783 def determine_plot_style(self, current_value, hole_data, i, cmap, norm):
1784 if hasattr(self, 'isolate_column') and self.isolate_column:
1785 value = hole_data[self.isolate_column].iloc[i]
1786 if pd.api.types.is_numeric_dtype(self.data[self.isolate_column]):
1787 value_in_range = self.isolate_range[0] <= value <= self.isolate_range[1]
1788 else:
1789 value_in_range = value == self.isolate_value
1790
1791 if value_in_range:
1792 # For values within the range, return the normal style
1793 return cmap(norm(current_value)), self.line_width, 1.0, 5
1794 else:
1795 # For values outside the range, return the 'inactive' style
1796 return 'black', 0.3, 1, 4 # Reduced alpha and lower zorder
1797 else:
1798 # If no isolation is set, return the normal style
1799 return cmap(norm(current_value)), self.line_width, 1.0, 5
1800
1801
1802 def plot(self): # Main drill hole plotting function

Callers 1

plotMethod · 0.95

Calls

no outgoing calls

Tested by

no test coverage detected