BoxPlotView
Base class for creating box plots.
:property x_label: The X-axis label :type x_label: str :property y_label: The Y-axis label :type y_label: str :property x_tick_labels: The labels of X-ticks :type x_tick_labels: list[str]
The view model is:
{
"type": "box-plot-view",
"title": str,
"caption": str,
"data": {
"x_label": str,
"y_label": str,
"x_tick_labels": List[str] | None,
"series": [
{
"data": {
"x": List[Float],
"max": List[Float],
"q1": List[Float],
"median": List[Float],
"min": List[Float],
"q3": List[Float],
"lower_whisker": List[Float],
"upper_whisker": List[Float],
"tags": List[Dict[str,str]] | None
},
"name": str
},
...
]
}
}
Attributes
x_label: str
x_tick_labels: List
y_label: str
Functions
Initialize self. See help(type(self)) for accurate signature.
Add series of raw data.
Name | Type | Default value | Description |
---|---|---|---|
data | List | Dataframe or [list[float]] | |
name | str | ||
tags | List | [dict[str, str]] |
Name | Type | Default value | Description |
---|---|---|---|
data | DataFrame | ||
name | str | ||
tags | List |
Add series of pre-computed x and y box values. Vector x is the vector of bin centers and y contains the magnitudes at corresponding x positions.
Name | Type | Default value | Description |
---|---|---|---|
x | List | List of float | |
median | List | List of float | |
q1 | List | List of float | |
q3 | List | List of float | |
min | List | List of float | |
max | List | List of float | |
lower_whisker | List | List of float | |
upper_whisker | List | List of float | |
name | str | ||
tags | List | [dict[str, str]] |
Add technical info
Name | Type | Default value | Description |
---|---|---|---|
technical_info | TechnicalInfo |
Copy the view information from another view
Name | Type | Default value | Description |
---|---|---|---|
view | View | View to copy the information from |
Convert to dictionary
Name | Type | Default value | Description |
---|---|---|---|
params | ConfigParams |
dict |
Mark the view as not interactive, disable the pagination
Get style
TypingStyle |
Get technical info dict
Name | Type | Default value | Description |
---|---|---|---|
key | str |
TechnicalInfo |
Get technical info
TechnicalInfoDict |
Get title
Optional |
Get type
ViewType |
Is favorite
bool |
Is interaction disabled
bool |
Set favorite
Name | Type | Default value | Description |
---|---|---|---|
favorite | bool |
Set typing style for this view instance. This overrides the style defines in the view decorator and the default style of the view type With this you can define a custom style for a specific view instance when you view is generic.
Name | Type | Default value | Description |
---|---|---|---|
style | TypingStyle |
Set technical info
Name | Type | Default value | Description |
---|---|---|---|
technical_info | TechnicalInfoDict |
Set title
Name | Type | Default value | Description |
---|---|---|---|
title | str |
Convert to DTO
Name | Type | Default value | Description |
---|---|---|---|
params | ConfigParams |
ViewDTO |
Generate range list like 0,1,2...length
Name | Type | Default value | Description |
---|---|---|---|
length | int |
List |
Dict |
Method that return true is the provided json is a json of a view
Name | Type | Default value | Description |
---|---|---|---|
json_ | Any |
bool |