wallaroo.assays_v2.assay_result_v2


This module features classes related to an assay v2 result that help with analysis and visualization for uploaded assays.

class AssayResultV2(wallaroo.wallaroo_ml_ops_api_client.models.assay_result_v2.AssayResultV2):

This class implements the IAssayAnalysis interface that offers a number of methods for analyzing and visualizing assay results.

Attributes: - parent_assay: The AssayV2 object that this result belongs to. - raw: The raw AssayResultV2 object from the Wallaroo ML Ops API client.

AssayResultV2( parent_assay: wallaroo.assays_v2.assay_v2.AssayV2, mlops_assay_result: wallaroo.wallaroo_ml_ops_api_client.models.assay_result_v2.AssayResultV2)

Initializes the AssayResultV2 object.

v1_iopath: str

Convert the v2 iopath to a v1 iopath.

def chart(self, show_scores: bool = True) -> None:

Create a chart showing the bins, values and scores of an assay result. show_scores will also label each bin with its final weighted (if specified) score.

Parameters
  • show_scores: Whether to show the scores for each bin.
def compare_basic_stats(self) -> pandas.core.frame.DataFrame:

Compare basic stats between baseline and window.

Returns

A dataframe including stats, start and end times for the window against the baseline.

def compare_bins(self) -> pandas.core.frame.DataFrame:

Compare bins between baseline and window.

Returns

A dataframe including edges, labels and values for the window against the baseline.

def to_df_row(self) -> Dict[str, Any]:

Convert the preview result to a dataframe row.

Returns

A dataframe row.

class AssayResultsList(typing.List[wallaroo.assays_v2.assay_result_v2.AssayResultV2]):

This class implements the IAssayAnalysisList interface that offers a number of methods for analyzing and visualizing a list of assay results.

Attributes: - parent_assay: The AssayV2 object that this result belongs to.

Initializes the AssayResultsList object.

def chart_iopaths( self, labels: Optional[List[str]] = None, selected_labels: Optional[List[str]] = None, nth_x_tick: Optional[int] = None) -> None:

Create a basic chart of the scores for each unique iopath of an AssayResultsList.

Parameters
  • labels: Custom labels for each unique iopath. If provided, these labels will be used in chart titles instead of raw iopath values.
  • selected_labels: Labels to filter which iopaths to chart. If provided, only iopaths with labels in this list will be charted.
  • nth_x_tick: Controls the density of x ticks. Every nth x tick will be used for the chart.
def chart_scores( self, title: Optional[str] = None, nth_x_tick: Optional[int] = 4, start: Optional[datetime.datetime] = None, end: Optional[datetime.datetime] = None) -> None:

Create a chart of the scores from a dataframe representation of an AssayResultsList.

Parameters
  • title: The title of the chart.
  • nth_x_tick: Controls the density of x ticks. Every nth x tick will be used for the chart.
  • start: The start time of the chart. Both start and end have to be provided to be used.
  • end: The end time of the chart. Both start and end have to be provided to be used.
def to_dataframe(self) -> pandas.core.frame.DataFrame:

Convert an AssayResultsList to a dataframe.

Returns

A dataframe representation of the list of assay results.

def to_full_dataframe(self) -> pandas.core.frame.DataFrame:

Convert an AssayResultsList to a full dataframe.

Returns

A dataframe representation of the list of assay results.

Inherited Members
builtins.list
clear
copy
append
insert
extend
pop
remove
index
count
reverse
sort