MCPcopy Create free account
hub / github.com/seleniumbase/SeleniumBase / create_area_chart

Method create_area_chart

seleniumbase/fixtures/base_case.py:12847–12892  ·  view source on GitHub ↗

Creates a JavaScript area chart using "HighCharts". @Params chart_name - If creating multiple charts, use this to select which one. title - The title displayed for the chart. subtitle - The subtitle displayed for the chart. data_name - The

(
        self,
        chart_name=None,
        title=None,
        subtitle=None,
        data_name=None,
        unit=None,
        zero=False,
        libs=True,
        labels=True,
        legend=True,
    )

Source from the content-addressed store, hash-verified

12845 )
12846
12847 def create_area_chart(
12848 self,
12849 chart_name=None,
12850 title=None,
12851 subtitle=None,
12852 data_name=None,
12853 unit=None,
12854 zero=False,
12855 libs=True,
12856 labels=True,
12857 legend=True,
12858 ):
12859 """Creates a JavaScript area chart using "HighCharts".
12860 @Params
12861 chart_name - If creating multiple charts,
12862 use this to select which one.
12863 title - The title displayed for the chart.
12864 subtitle - The subtitle displayed for the chart.
12865 data_name - The series name. Useful for multi-series charts.
12866 If no data_name, will default to using "Series 1".
12867 unit - The description label given to the chart's y-axis values.
12868 zero - If True, the y-axis always starts at 0. (Default: False).
12869 libs - The option to include Chart libraries (JS and CSS files).
12870 Should be set to True (default) for the first time creating
12871 a chart on a web page. If creating multiple charts on the
12872 same web page, you won't need to re-import the libraries
12873 when creating additional charts.
12874 labels - If True, displays labels on the chart for data points.
12875 legend - If True, displays the data point legend on the chart."""
12876 if not chart_name:
12877 chart_name = "default"
12878 if not data_name:
12879 data_name = ""
12880 style = "area"
12881 self.__create_highchart(
12882 chart_name=chart_name,
12883 title=title,
12884 subtitle=subtitle,
12885 style=style,
12886 data_name=data_name,
12887 unit=unit,
12888 zero=zero,
12889 libs=libs,
12890 labels=labels,
12891 legend=legend,
12892 )
12893
12894 def __create_highchart(
12895 self,

Calls 1

__create_highchartMethod · 0.95

Tested by 1

test_area_chartMethod · 0.64