Skip to content

Commit

Permalink
Addressing review comments
Browse files Browse the repository at this point in the history
  • Loading branch information
harsh97 committed Sep 20, 2023
1 parent b2952bd commit 96e8ed4
Show file tree
Hide file tree
Showing 3 changed files with 22 additions and 0 deletions.
6 changes: 6 additions & 0 deletions THIRD_PARTY_LICENSES.txt
Original file line number Diff line number Diff line change
Expand Up @@ -229,6 +229,12 @@ pandavro
* Source code: https://github.com/ynqa/pandavro
* Project home: https://github.com/ynqa/pandavro

plotly
* Copyright (c) 2016-2018 Plotly, Inc
* License: MIT License
* Source code: https://github.com/plotly/plotly.py
* Project home: https://plotly.com/

protobuf
* Copyright 2008 Google Inc. All rights reserved.
* License: Google Protobuf License
Expand Down
10 changes: 10 additions & 0 deletions ads/feature_store/statistics/charts/box_plot.py
Original file line number Diff line number Diff line change
Expand Up @@ -66,6 +66,16 @@ def __init__(
self.box_points = box_points
super().__init__()

def __validate__(self):
if (
self.q1 is None
or self.q3 is None
or self.iqr is None
or type(self.box_points) is not list
or len(self.box_points) == 0
):
return self.ValidationFailedException()

def add_to_figure(self, fig: Figure, xaxis: int, yaxis: int):
xaxis_str, yaxis_str, x_str, y_str = self.get_x_y_str_axes(xaxis, yaxis)
fig.add_box(
Expand Down
6 changes: 6 additions & 0 deletions ads/feature_store/statistics/statistics.py
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,12 @@ def kind(self) -> str:
return "statistics"

def to_viz(self, feature_list: List[str] = None):
"""Visualises statistics inside notebook
Parameters
----------
feature_list: (str, optional). Defaults to `None`.
The specific features of the FeatureGroup or Dataset we want to visualise
"""
if self.content is not None:
[
FeatureStatistics.from_json(feature, stat).to_viz()
Expand Down

0 comments on commit 96e8ed4

Please sign in to comment.