package com.anychart.enums;

import java.util.Locale;

/**
 * Statistics enumeration.
 */
public enum Statistics {

    AVERAGE("average"),
    BUBBLE_SIZE("bubbleSize"),
    BUBBLE_SIZE_PERCENT_OF_CATEGORY("bubbleSizePercentOfCategory"),
    BUBBLE_SIZE_PERCENT_OF_SERIES("bubbleSizePercentOfSeries"),
    BUBBLE_SIZE_PERCENT_OF_TOTAL("bubbleSizePercentOfTotal"),
    CATEGORY_NAME("categoryName"),
    CATEGORY_Y_AVERAGE("categoryYAverage"),
    CATEGORY_Y_MAX("categoryYMax"),
    CATEGORY_Y_MEDIAN("categoryYMedian"),
    CATEGORY_Y_MIN("categoryYMin"),
    CATEGORY_Y_MODE("categoryYMode"),
    CATEGORY_Y_PERCENT_OF_TOTAL("categoryYPercentOfTotal"),
    CATEGORY_Y_RANGE_AVERAGE("categoryYRangeAverage"),
    CATEGORY_Y_RANGE_MAX("categoryYRangeMax"),
    CATEGORY_Y_RANGE_MEDIAN("categoryYRangeMedian"),
    CATEGORY_Y_RANGE_MIN("categoryYRangeMin"),
    CATEGORY_Y_RANGE_MODE("categoryYRangeMode"),
    CATEGORY_Y_RANGE_PERCENT_OF_TOTAL("categoryYRangePercentOfTotal"),
    CATEGORY_Y_RANGE_SUM("categoryYRangeSum"),
    CATEGORY_Y_SUM("categoryYSum"),
    CHART_ELEMENTS("chartElements"),
    CLOSE("close"),
    COUNT("count"),
    DATA_PLOT_BUBBLE_MAX_SIZE("dataPlotBubbleMaxSize"),
    DATA_PLOT_BUBBLE_MIN_SIZE("dataPlotBubbleMinSize"),
    DATA_PLOT_BUBBLE_SIZE_AVERAGE("dataPlotBubbleSizeAverage"),
    DATA_PLOT_BUBBLE_SIZE_SUM("dataPlotBubbleSizeSum"),
    DATA_PLOT_MAX_X_SUM_SERIES_NAME("dataPlotMaxXSumSeriesName"),
    DATA_PLOT_MAX_X_VALUE_POINT_SERIES_NAME("dataPlotMaxXValuePointSeriesName"),
    DATA_PLOT_MAX_Y_SUM_SERIES_NAME("dataPlotMaxYSumSeriesName"),
    DATA_PLOT_MAX_Y_VALUE_POINT_SERIES_NAME("dataPlotMaxYValuePointSeriesName"),
    DATA_PLOT_MIN_X_SUM_SERIES_NAME("dataPlotMinXSumSeriesName"),
    DATA_PLOT_MIN_X_VALUE_POINT_SERIES_NAME("dataPlotMinXValuePointSeriesName"),
    DATA_PLOT_MIN_Y_SUM_SERIES_NAME("dataPlotMinYSumSeriesName"),
    DATA_PLOT_MIN_Y_VALUE_POINT_SERIES_NAME("dataPlotMinYValuePointSeriesName"),
    DATA_PLOT_POINT_COUNT("dataPlotPointCount"),
    DATA_PLOT_SERIES_COUNT("dataPlotSeriesCount"),
    DATA_PLOT_X_AVERAGE("dataPlotXAverage"),
    DATA_PLOT_X_MAX("dataPlotXMax"),
    DATA_PLOT_X_MIN("dataPlotXMin"),
    DATA_PLOT_X_SUM("dataPlotXSum"),
    DATA_PLOT_Y_AVERAGE("dataPlotYAverage"),
    DATA_PLOT_Y_MAX("dataPlotYMax"),
    DATA_PLOT_Y_MIN("dataPlotYMin"),
    DATA_PLOT_Y_RANGE_MAX("dataPlotYRangeMax"),
    DATA_PLOT_Y_RANGE_MIN("dataPlotYRangeMin"),
    DATA_PLOT_Y_RANGE_SUM("dataPlotYRangeSum"),
    DATA_PLOT_Y_SUM("dataPlotYSum"),
    HIGH("high"),
    INDEX("index"),
    LEVELS("levels"),
    LOW("low"),
    MAX("max"),
    MIN("min"),
    NAME("name"),
    OPEN("open"),
    PERT_CHART_CRITICAL_PATH_STANDARD_DEVIATION("pertChartCriticalPathStandardDeviation"),
    PERT_CHART_PROJECT_DURATION("pertChartProjectDuration"),
    POINTS_COUNT("pointsCount"),
    RANGE("range"),
    RANGE_END("rangeEnd"),
    RANGE_START("rangeStart"),
    SERIES_AVERAGE("seriesAverage"),
    SERIES_BUBBLE_MAX_SIZE("seriesBubbleMaxSize"),
    SERIES_BUBBLE_MIN_SIZE("seriesBubbleMinSize"),
    SERIES_BUBBLE_SIZE_AVERAGE("seriesBubbleSizeAverage"),
    SERIES_BUBBLE_SIZE_MEDIAN("seriesBubbleSizeMedian"),
    SERIES_BUBBLE_SIZE_MODE("seriesBubbleSizeMode"),
    SERIES_BUBBLE_SIZE_SUM("seriesBubbleSizeSum"),
    SERIES_FIRST_X_VALUE("seriesFirstXValue"),
    SERIES_FIRST_Y_VALUE("seriesFirstYValue"),
    SERIES_LAST_X_VALUE("seriesLastXValue"),
    SERIES_LAST_Y_VALUE("seriesLastYValue"),
    SERIES_MAX("seriesMax"),
    SERIES_MIN("seriesMin"),
    SERIES_NAME("seriesName"),
    SERIES_POINTS_COUNT("seriesPointsCount"),
    SERIES_POINT_COUNT("seriesPointCount"),
    SERIES_SUM("seriesSum"),
    SERIES_X_AVERAGE("seriesXAverage"),
    SERIES_X_MAX("seriesXMax"),
    SERIES_X_MEDIAN("seriesXMedian"),
    SERIES_X_MIN("seriesXMin"),
    SERIES_X_MODE("seriesXMode"),
    SERIES_X_SUM("seriesXSum"),
    SERIES_Y_AVERAGE("seriesYAverage"),
    SERIES_Y_MAX("seriesYMax"),
    SERIES_Y_MEDIAN("seriesYMedian"),
    SERIES_Y_MIN("seriesYMin"),
    SERIES_Y_MODE("seriesYMode"),
    SERIES_Y_RANGE_AVERAGE("seriesYRangeAverage"),
    SERIES_Y_RANGE_MAX("seriesYRangeMax"),
    SERIES_Y_RANGE_MEDIAN("seriesYRangeMedian"),
    SERIES_Y_RANGE_MIN("seriesYRangeMin"),
    SERIES_Y_RANGE_MODE("seriesYRangeMode"),
    SERIES_Y_RANGE_SUM("seriesYRangeSum"),
    SERIES_Y_SUM("seriesYSum"),
    SUM("sum"),
    VALUE("value"),
    X_PERCENT_OF_SERIES("xPercentOfSeries"),
    X_PERCENT_OF_TOTAL("xPercentOfTotal"),
    X_SCALES_MAX("xScalesMax"),
    X_SCALES_MIN("xScalesMin"),
    X_VALUE("xValue"),
    Y_PERCENT_OF_CATEGORY("yPercentOfCategory"),
    Y_PERCENT_OF_SERIES("yPercentOfSeries"),
    Y_PERCENT_OF_TOTAL("yPercentOfTotal"),
    Y_SCALES_MAX("yScalesMax"),
    Y_SCALES_MIN("yScalesMin"),
    Y_VALUE("yValue");

    private final String value;

    Statistics(String value) {
        this.value = value;
    }

    public String getJsBase() {
        return String.format(Locale.US, "\"%s\"", value);
    }
}