webinterface.pages.base_pages.utils.resulttable module#
- webinterface.pages.base_pages.utils.resulttable.configure_aggrid(df: DataFrame)[source]#
Configures the styling and options for AgGrid based on column category.
- Parameters:
df (pd.DataFrame) – The display-ready DataFrame.
- Returns:
AgGrid gridOptions dictionary.
- Return type:
- webinterface.pages.base_pages.utils.resulttable.prepare_display_dataframe(df: DataFrame, highlight_id: str | None) DataFrame[source]#
Prepares the DataFrame for display, including column filtering, ordering, row highlighting, and numeric formatting.
- Parameters:
df (pd.DataFrame) – The filtered dataset for display.
highlight_id (str or None) – The ProteoBench ID to highlight (adds a marker in the ‘selected’ column).
- Returns:
A formatted and sorted DataFrame ready for rendering.
- Return type:
pd.DataFrame
- webinterface.pages.base_pages.utils.resulttable.render_aggrid(df: DataFrame, grid_options, key)[source]#
Renders a DataFrame using AgGrid with specified grid options and a unique key.
- Parameters:
df (pd.DataFrame) – The DataFrame to display in the grid.
grid_options (dict) – Configuration options for AgGrid.
key (Any) – Unique identifier for the grid instance (AgGrid does not work with UUID keys).
- Returns:
This function renders the grid in the Streamlit interface and does not return a value.
- Return type:
None