GraphPlotly Module

class epyk.core.html.graph.GraphPlotly.Bar(page, width, height, options, html_code, profile)
add_trace(data, type='bar', mode=None)
Parameters:
  • data

  • type

  • mode

property chart: Bar

JsPlotly.Bar

Type:

rtype

property layout: LayoutBar

Layout

Type:

rtype

class epyk.core.html.graph.GraphPlotly.Box(page, width, height, options, html_code, profile)
add_trace(data, type='box', mode=None)
Parameters:
  • data

  • type

  • mode

property chart: Pie

JsPlotly.Pie

Type:

rtype

property layout: LayoutBox

LayoutBox

Type:

rtype

class epyk.core.html.graph.GraphPlotly.CandleStick(page, width, height, options, html_code, profile)
add_trace(data, type='candlestick', mode=None)
Parameters:
  • data

  • type

  • mode

property chart: Pie

JsPlotly.Pie

Type:

rtype

property layout: LayoutBox

LayoutBox

Type:

rtype

class epyk.core.html.graph.GraphPlotly.Chart(page, width, height, options, html_code, profile)
add_trace(data, type=None, mode=None)
Parameters:
  • data

  • type

  • mode

build(data=None, options: Optional[Union[bool, dict]] = None, profile: Optional[Union[bool, dict]] = None, component_id: Optional[str] = None)
Parameters:
  • data

  • options

  • profile

  • component_id

property chartId: str

Return the Javascript variable of the chart.

click(js_funcs: Union[List[Union[str, JsDataModel]], str], profile: Optional[Union[bool, dict]] = None, source_event: Optional[str] = None, on_ready: bool = False)

The onclick event occurs when the user clicks on an element.

Related Pages:

Parameters:
  • js_funcs – A Javascript Python function

  • profile – Optional. Set to true to get the profile for the function on the Javascript console

  • source_event – Optional. The source target for the event

  • on_ready – Optional. Specify if the event needs to be trigger when the page is loaded

click_legend(js_funcs: Union[List[Union[str, JsDataModel]], str], profile: Optional[Union[bool, dict]] = None)

Related Pages:

Parameters:
  • js_funcs – Javascript functions

  • profile – Optional. A flag to set the component performance storage

colors(hex_values: List[str])

Set the colors of the chart.

hex_values can be a list of string with the colors or a list of tuple to also set the bg colors. If the background colors are not specified they will be deduced from the colors list changing the opacity.

Usage:

:param hex_values: An array of hexadecimal color codes.
property d3

JsD3.D3Select

Type:

rtype

property data
dblclick(js_funcs: Union[List[Union[str, JsDataModel]], str], profile: Optional[Union[bool, dict]] = None, source_event: Optional[str] = None, on_ready: bool = False)

The onDblclick event occurs when the user double clicks on an element.

Related Pages:

Parameters:
  • js_funcs – A Javascript Python function

  • profile – Optional. Set to true to get the profile for the function on the Javascript console

  • source_event – Optional. The source target for the event

  • on_ready – Optional. Specify if the event needs to be trigger when the page is loaded

hover(js_funcs: Union[List[Union[str, JsDataModel]], str], profile: Optional[Union[bool, dict]] = None, source_event: Optional[str] = None, on_ready: bool = False)

Related Pages:

Parameters:
  • js_funcs – A Javascript Python function

  • profile – Optional. Set to true to get the profile for the function on the Javascript console

  • source_event – Optional. The source target for the event

  • on_ready – Optional. Specify if the event needs to be trigger when the page is loaded

property js: JsPlotly

Javascript base function.

Return all the Javascript functions defined in the framework. This is an entry point to the full Javascript ecosystem.

Returns:

A Javascript object

Return type:

JsPlotly.JsPlotly

property layout

Layout

Type:

rtype

property options: OptionConfig

Property to the component options. Options can either impact the Python side or the Javascript builder.

Python can pass some options to the JavaScript layer.

property shared: OptionsChartSharedPlotly

All the common properties shared between all the charts. This will ensure a compatibility with the plot method.

Usage:

line = page.ui.charts.bb.bar()
line.shared.x_label("x axis")
traces(i: Optional[int] = None)
Return type:

JsChartJs.DataSetPie

unhover(js_funcs: Union[List[Union[str, JsDataModel]], str], profile: Optional[Union[bool, dict]] = None, source_event: Optional[str] = None, on_ready: bool = False)

Related Pages:

Parameters:
  • js_funcs – A Javascript Python function

  • profile – Optional. Set to true to get the profile for the function on the Javascript console

  • source_event – Optional. The source target for the event

  • on_ready – Optional. Specify if the event needs to be trigger when the page is loaded

class epyk.core.html.graph.GraphPlotly.DataBox(component: Optional[HtmlModel] = None, attrs: Optional[dict] = None, options: Optional[dict] = None, page: Optional[PageModel] = None)
class epyk.core.html.graph.GraphPlotly.DataCandle(component: Optional[HtmlModel] = None, attrs: Optional[dict] = None, options: Optional[dict] = None, page: Optional[PageModel] = None)
property decreasing

DataMove

Returns:

Type:

rtype

property increasing

DataMove

Returns:

Type:

rtype

class epyk.core.html.graph.GraphPlotly.DataChart(component: Optional[HtmlModel] = None, attrs: Optional[dict] = None, options: Optional[dict] = None, page: Optional[PageModel] = None)
axis_index(x, y=None)
Parameters:
  • x

  • y

property marker

//plot.ly/javascript/bubble-charts/

Return type:

DataMarkers

Type:

https

class epyk.core.data.DataClass.DataClass(component: Optional[HtmlModel] = None, attrs: Optional[dict] = None, options: Optional[dict] = None, page: Optional[PageModel] = None)
add(name: str, value: Any)

Add the key and value to the final result object.

Parameters:
  • name – The key in the final data dictionary.

  • value – The value in the final data dictionary.

attr(name: str, value: Any)

Add an attribute to the Javascript underlying dictionary.

Parameters:
  • name – The attribute name

  • value – The attribute value

Returns:

“Self” to allow the chains on the Python side

attrs()
custom(name: str, value: Any)

Custom function to add a bespoke attribute to a class.

This entry point will not be able to display any documentation but it is a shortcut to test new features. If the value is a Javascript object, the PyJs object must be used.

Parameters:
  • name – The key to be added to the attributes

  • value – The value of the defined attributes

Returns:

The DataAttrs to allow the chains

get(dfl: Optional[Union[str, bool, int, dict, list, float]] = None, name: Optional[str] = None)

Get the attribute to the underlying attributes dictionary.

Parameters:
  • dfl – Optional. The default value of this attribute

  • name – Optional. The attribute name. default the name of the function

has_attribute(cls_obj)

Add an extra sub layer to the data structure.

The key in the object representation will be the function name.

Parameters:

cls_obj – Class. The sub data class used in the structure definition

set(value: Any, name: Optional[str] = None)

Add an attribute to the Javascript underlying dictionary.

Parameters:
  • value – The attribute value

  • name – Optional. The attribute name. default the name of the functin.

Returns:

“Self” to allow the chains on the Python side

sub_data(name: str, cls_obj)

Add an extra sub layer to the data structure. The key in the object representation will be the function name.

Should use has_attribute is the name can be deduced from the parent function.

Parameters:
  • name – The key to be added to the internal data dictionary

  • cls_obj – Class. Object. The object which will be added to the nested data structure

sub_data_enum(name: str, cls_obj)

Add key to a sub dictionary. This will create an attribute object with a nested structure.

Parameters:
  • name – The key to be added to the internal data dictionary

  • cls_obj – Class. Object. The object which will be added to the nested data structure

update(vals: dict)

Update the object internal attributes.

Parameters:

vals – All the attributes to be added to the component

class epyk.core.html.graph.GraphPlotly.DataContours(component: Optional[HtmlModel] = None, attrs: Optional[dict] = None, options: Optional[dict] = None, page: Optional[PageModel] = None)
property z

//plot.ly/javascript/3d-surface-plots/

Return type:

DataZ

Type:

https

class epyk.core.html.graph.GraphPlotly.DataDelta(component: Optional[HtmlModel] = None, attrs: Optional[dict] = None, options: Optional[dict] = None, page: Optional[PageModel] = None)
class epyk.core.html.graph.GraphPlotly.DataFill(component: Optional[HtmlModel] = None, attrs: Optional[dict] = None, options: Optional[dict] = None, page: Optional[PageModel] = None)
class epyk.core.html.graph.GraphPlotly.DataFont(component: Optional[HtmlModel] = None, attrs: Optional[dict] = None, options: Optional[dict] = None, page: Optional[PageModel] = None)
class epyk.core.html.graph.GraphPlotly.DataGauge(component: Optional[HtmlModel] = None, attrs: Optional[dict] = None, options: Optional[dict] = None, page: Optional[PageModel] = None)
property axis

//plot.ly/javascript/indicator/

Return type:

LayoutAxis

Type:

https

class epyk.core.html.graph.GraphPlotly.DataIndicator(component: Optional[HtmlModel] = None, attrs: Optional[dict] = None, options: Optional[dict] = None, page: Optional[PageModel] = None)
add_title("<b style='color:red'>test</b>")

https://plot.ly/javascript/indicator/

Parameters:

text

Returns:

property delta

//plot.ly/javascript/3d-surface-plots/

Return type:

DataDelta

Type:

https

domain(x, y)

https://plot.ly/javascript/indicator/

Parameters:
  • x

  • y

property gauge

//plot.ly/javascript/indicator/

Return type:

DataGauge

Type:

https

property number

//plot.ly/javascript/indicator/

Return type:

DataNumber

Type:

https

property title

//plot.ly/javascript/indicator/

Return type:

DataTitle

Type:

https

class epyk.core.html.graph.GraphPlotly.DataLine(component: Optional[HtmlModel] = None, attrs: Optional[dict] = None, options: Optional[dict] = None, page: Optional[PageModel] = None)
class epyk.core.html.graph.GraphPlotly.DataMarkers(component: Optional[HtmlModel] = None, attrs: Optional[dict] = None, options: Optional[dict] = None, page: Optional[PageModel] = None)
property line

//plot.ly/javascript/webgl-vs-svg/

Return type:

DataMarkersLine

Type:

https

property outliercolor

//plot.ly/javascript/box-plots/

Type:

https

class epyk.core.html.graph.GraphPlotly.DataMarkersLine(component: Optional[HtmlModel] = None, attrs: Optional[dict] = None, options: Optional[dict] = None, page: Optional[PageModel] = None)
class epyk.core.html.graph.GraphPlotly.DataMove(component: Optional[HtmlModel] = None, attrs: Optional[dict] = None, options: Optional[dict] = None, page: Optional[PageModel] = None)
property line

DataLine

Returns:

Type:

rtype

class epyk.core.html.graph.GraphPlotly.DataNumber(component: Optional[HtmlModel] = None, attrs: Optional[dict] = None, options: Optional[dict] = None, page: Optional[PageModel] = None)
class epyk.core.html.graph.GraphPlotly.DataPie(component: Optional[HtmlModel] = None, attrs: Optional[dict] = None, options: Optional[dict] = None, page: Optional[PageModel] = None)
property outsidetextfont

Sets the font used for textinfo lying outside the sector.

https://plot.ly/javascript/reference/#pie-outsidetextfont-family

Return type:

DataFont

class epyk.core.html.graph.GraphPlotly.DataProject(component: Optional[HtmlModel] = None, attrs: Optional[dict] = None, options: Optional[dict] = None, page: Optional[PageModel] = None)
class epyk.core.html.graph.GraphPlotly.DataSurface(component: Optional[HtmlModel] = None, attrs: Optional[dict] = None, options: Optional[dict] = None, page: Optional[PageModel] = None)
property contours

//plot.ly/javascript/3d-surface-plots/

Return type:

DataContours

Type:

https

property line

DataLine

Returns:

Type:

rtype

class epyk.core.html.graph.GraphPlotly.DataTitle(component: Optional[HtmlModel] = None, attrs: Optional[dict] = None, options: Optional[dict] = None, page: Optional[PageModel] = None)
class epyk.core.html.graph.GraphPlotly.DataXY(component: Optional[HtmlModel] = None, attrs: Optional[dict] = None, options: Optional[dict] = None, page: Optional[PageModel] = None)
class epyk.core.html.graph.GraphPlotly.DataZ(component: Optional[HtmlModel] = None, attrs: Optional[dict] = None, options: Optional[dict] = None, page: Optional[PageModel] = None)
property project

//plot.ly/javascript/3d-surface-plots/

Return type:

DataProject

Type:

https

class epyk.core.html.graph.GraphPlotly.Indicator(page, width, height, options, html_code, profile)
add_trace(data, type='indicator', mode=None)
Parameters:
  • data

  • type

  • mode

property chart: Pie

JsPlotly.Pie

Type:

rtype

class epyk.core.html.graph.GraphPlotly.Layout(component: Optional[HtmlModel] = None, attrs: Optional[dict] = None, options: Optional[dict] = None, page: Optional[PageModel] = None)
property annotations

//plot.ly/javascript/shapes/

Return type:

LayoutAnnotation

Type:

https

axis_colors(x_color, y_color=None)
Parameters:
  • x_color

  • y_color

Returns:

property grid

//plot.ly/javascript/subplots/

Return type:

LayoutGrid

Type:

https

grid_colors(x_color, y_color=None)
Parameters:
  • x_color

  • y_color

Returns:

inset_trace(x_domain, x, y=None, y_domain=None)

https://plot.ly/javascript/insets/

Parameters:
  • x_domain

  • x

  • y

  • y_domain

property legend

//plot.ly/javascript/legend/

Return type:

LayoutLegend

Type:

https

property margin

//plot.ly/javascript/3d-surface-plots/

Return type:

LayoutMargin

Type:

https

no_background()

https://community.plot.ly/t/you-can-remove-the-white-background-of-the-graphics-background/933

Returns:

no_grid()

Remove the vertical and horizontal sub axis from the chart display. Keep the zeroline axis

Returns:

The attribute object to allow the chaining

property scene

LayoutScene

Type:

rtype

property shapes

//plot.ly/javascript/shapes/

Return type:

LayoutShape

Type:

https

property title

LayoutTitle

Type:

rtype

property xaxis

//plot.ly/javascript/time-series/

Return type:

LayoutAxis

Type:

https

property xaxis2

//plot.ly/javascript/time-series/

Return type:

LayoutAxis

Type:

https

property yaxis

//plot.ly/javascript/time-series/

Return type:

LayoutAxis

Type:

https

property yaxis2

//plot.ly/javascript/time-series/

Return type:

LayoutAxis

Type:

https

class epyk.core.html.graph.GraphPlotly.Layout3D(component: Optional[HtmlModel] = None, attrs: Optional[dict] = None, options: Optional[dict] = None, page: Optional[PageModel] = None)
axis_colors(x_color, y_color=None, z_color=None)
Parameters:
  • x_color

  • y_color

  • z_color

Returns:

grid_colors(x_color, y_color=None, z_color=None)
Parameters:
  • x_color

  • y_color

  • z_color

property scene

LayoutScene

Type:

rtype

class epyk.core.html.graph.GraphPlotly.LayoutAnnotation(component: Optional[HtmlModel] = None, attrs: Optional[dict] = None, options: Optional[dict] = None, page: Optional[PageModel] = None)
class epyk.core.html.graph.GraphPlotly.LayoutAxis(component: Optional[HtmlModel] = None, attrs: Optional[dict] = None, options: Optional[dict] = None, page: Optional[PageModel] = None)
property rangeselector: LayoutRangeSelector

//plot.ly/javascript/time-series/

Return type:

LayoutRangeSelector

Type:

https

property rangeslider: LayoutRangeSlider

//plot.ly/javascript/time-series/

Return type:

LayoutRangeSlider

Type:

https

set_color(color)
Parameters:

color

property tickfont: LayoutFont

LayoutFont

Returns:

Type:

rtype

property titlefont: LayoutFont

LayoutFont

Returns:

Type:

rtype

class epyk.core.html.graph.GraphPlotly.LayoutBar(component: Optional[HtmlModel] = None, attrs: Optional[dict] = None, options: Optional[dict] = None, page: Optional[PageModel] = None)
class epyk.core.html.graph.GraphPlotly.LayoutBox(component: Optional[HtmlModel] = None, attrs: Optional[dict] = None, options: Optional[dict] = None, page: Optional[PageModel] = None)
class epyk.core.html.graph.GraphPlotly.LayoutButtons(component: Optional[HtmlModel] = None, attrs: Optional[dict] = None, options: Optional[dict] = None, page: Optional[PageModel] = None)
class epyk.core.html.graph.GraphPlotly.LayoutCamera(component: Optional[HtmlModel] = None, attrs: Optional[dict] = None, options: Optional[dict] = None, page: Optional[PageModel] = None)
property eye: LayoutEye

LayoutEye

Returns:

Type:

rtype

class epyk.core.html.graph.GraphPlotly.LayoutEye(component: Optional[HtmlModel] = None, attrs: Optional[dict] = None, options: Optional[dict] = None, page: Optional[PageModel] = None)
class epyk.core.html.graph.GraphPlotly.LayoutFont(component: Optional[HtmlModel] = None, attrs: Optional[dict] = None, options: Optional[dict] = None, page: Optional[PageModel] = None)
property color

color or array of colors

Type:

prop color

property family

HTML font family - the typeface that will be applied by the web browser.

https://plot.ly/javascript/reference/#pie-outsidetextfont-family

Prop font-family:

string or array of strings

property size

//plot.ly/javascript/reference/#pie-outsidetextfont-family

Returns:

number or array of numbers greater than or equal to 1

Type:

https

class epyk.core.html.graph.GraphPlotly.LayoutGrid(component: Optional[HtmlModel] = None, attrs: Optional[dict] = None, options: Optional[dict] = None, page: Optional[PageModel] = None)
class epyk.core.html.graph.GraphPlotly.LayoutLegend(component: Optional[HtmlModel] = None, attrs: Optional[dict] = None, options: Optional[dict] = None, page: Optional[PageModel] = None)
property font: LayoutFont

LayoutFont

Type:

rtype

class epyk.core.html.graph.GraphPlotly.LayoutMargin(component: Optional[HtmlModel] = None, attrs: Optional[dict] = None, options: Optional[dict] = None, page: Optional[PageModel] = None)
class epyk.core.html.graph.GraphPlotly.LayoutRangeSelector(component: Optional[HtmlModel] = None, attrs: Optional[dict] = None, options: Optional[dict] = None, page: Optional[PageModel] = None)
property buttons: LayoutButtons

//plot.ly/javascript/time-series/ https://plot.ly/javascript/range-slider/

Return type:

LayoutButtons

Type:

https

class epyk.core.html.graph.GraphPlotly.LayoutRangeSlider(component: Optional[HtmlModel] = None, attrs: Optional[dict] = None, options: Optional[dict] = None, page: Optional[PageModel] = None)
class epyk.core.html.graph.GraphPlotly.LayoutScene(component: Optional[HtmlModel] = None, attrs: Optional[dict] = None, options: Optional[dict] = None, page: Optional[PageModel] = None)
property camera: LayoutCamera

LayoutCamera

Returns:

Type:

rtype

property xaxis: LayoutAxis

LayoutAxis

Returns:

Type:

rtype

property yaxis: LayoutAxis

LayoutAxis

Returns:

Type:

rtype

property zaxis: LayoutAxis

LayoutAxis

Returns:

Type:

rtype

class epyk.core.html.graph.GraphPlotly.LayoutShape(component: Optional[HtmlModel] = None, attrs: Optional[dict] = None, options: Optional[dict] = None, page: Optional[PageModel] = None)
add_circle(x, y, x1, y1, opacity=0.2, color=None)
Parameters:
  • x

  • y

  • x1

  • y1

  • opacity

  • color

add_line(-100, 10, -50, -10, color="red")
Parameters:
  • x

  • y

  • x1

  • y1

  • opacity

  • color

add_path(points, color: Optional[str] = None)

https://plot.ly/javascript/shapes/

Parameters:
  • points

  • color

add_rect(x, y, x1, y1, opacity=0.2, color=None)
Parameters:
  • x

  • y

  • x1

  • y1

  • opacity

  • color

property line

DataMarkersLine

Type:

rtype

class epyk.core.html.graph.GraphPlotly.Line(page, width, height, options, html_code, profile)
add_trace(data: Union[str, JsDataModel, float, dict, list, bool], type: Optional[str] = None, mode: str = 'lines+markers')
Parameters:
  • data

  • type

  • mode

trace(data: Union[str, JsDataModel, float, dict, list, bool], type: Optional[str] = None, mode: str = 'lines+markers')
Parameters:
  • data

  • type

  • mode

class epyk.core.html.graph.GraphPlotly.Mesh3d(page, width, height, options, html_code, profile)
add_trace(data, type='mesh3d', mode=None)
Parameters:
  • data

  • type

  • mode

property chart: Pie

JsPlotly.Pie

Type:

rtype

property data
class epyk.core.html.graph.GraphPlotly.Pie(page, width, height, options, html_code, profile)
add_trace(data, type='pie', mode=None)
Parameters:
  • data

  • type

  • mode

property chart: Pie

JsPlotly.Pie

Type:

rtype

property data: DataPie

DataPie

Returns:

Type:

rtype

class epyk.core.html.graph.GraphPlotly.Scatter3D(page, width, height, options, html_code, profile)
add_trace(data, type='scatter3d', mode='lines')
Parameters:
  • data

  • type

  • mode

property chart: Pie

JsPlotly.Pie

Type:

rtype

property data
property layout: Layout3D

Layout

Type:

rtype

class epyk.core.html.graph.GraphPlotly.ScatterPolar(page, width, height, options, html_code, profile)
add_trace(data, type='scatterpolar', mode=None)
Parameters:
  • data

  • type

  • mode

property chart: Pie

JsPlotly.Pie

Type:

rtype

class epyk.core.html.graph.GraphPlotly.Surface(page, width, height, options, html_code, profile)
add_trace(data, type='surface', mode=None)
Parameters:
  • data

  • type

  • mode

property chart: Pie

JsPlotly.Pie

Type:

rtype

property data