initialize() private method

Sets the histogram's bin ranges (edges).
private initialize ( double startValue, double width ) : void
startValue double
width double
return void
Exemplo n.º 1
0
        /// <summary>
        ///   Creates a new object that is a copy of the current instance.
        /// </summary>
        ///
        /// <returns>
        ///   A new object that is a copy of this instance.
        /// </returns>
        ///
        public object Clone()
        {
            Histogram clone = new Histogram();

            clone.initialize(this.values.Length);

            for (int i = 0; i < clone.ranges.Length; i++)
            {
                clone.ranges[i] = this.ranges[i];
            }

            for (int i = 0; i < clone.values.Length; i++)
            {
                clone.values[i] = this.values[i];
            }

            clone.cumulative          = this.cumulative;
            clone.inclusiveUpperBound = this.inclusiveUpperBound;
            clone.rule = this.rule;

            return(clone);
        }
Exemplo n.º 2
0
        /// <summary>
        ///   Creates a new object that is a copy of the current instance.
        /// </summary>
        /// 
        /// <returns>
        ///   A new object that is a copy of this instance.
        /// </returns>
        /// 
        public object Clone()
        {
            Histogram clone = new Histogram();
            clone.initialize(this.values.Length);

            for (int i = 0; i < clone.ranges.Length; i++)
                clone.ranges[i] = this.ranges[i];

            for (int i = 0; i < clone.values.Length; i++)
                clone.values[i] = this.values[i];

            clone.cumulative = this.cumulative;
            clone.inclusiveUpperBound = this.inclusiveUpperBound;
            clone.rule = this.rule;

            return clone;
        }