Ejemplo n.º 1
0
        /// <summary>
        /// Estimates the first quartile value from the provided samples.
        /// Approximately median-unbiased regardless of the sample distribution (R8).
        /// </summary>
        /// <param name="data">The data sample sequence.</param>
        public static double LowerQuartile(this IEnumerable <double?> data)
        {
            if (data == null)
            {
                throw new ArgumentNullException("data");
            }
            var array = data.Where(d => d.HasValue).Select(d => d.Value).ToArray();

            return(ArrayStatistics.LowerQuartileInplace(array));
        }
Ejemplo n.º 2
0
        /// <summary>
        /// Estimates the first quartile value from the provided samples.
        /// Approximately median-unbiased regardless of the sample distribution (R8).
        /// </summary>
        /// <param name="data">The data sample sequence.</param>
        public static double LowerQuartile(this IEnumerable <double> data)
        {
            if (data == null)
            {
                throw new ArgumentNullException("data");
            }
            var array = data.ToArray();

            return(ArrayStatistics.LowerQuartileInplace(array));
        }
Ejemplo n.º 3
0
        /// <summary>
        /// Estimates the first quartile value from the provided samples.
        /// Approximately median-unbiased regardless of the sample distribution (R8).
        /// </summary>
        /// <param name="data">The data sample sequence.</param>
        public static double LowerQuartile(this IEnumerable <double?> data)
        {
            var array = data.Where(d => d.HasValue).Select(d => d.Value).ToArray();

            return(ArrayStatistics.LowerQuartileInplace(array));
        }
Ejemplo n.º 4
0
        /// <summary>
        /// Estimates the first quartile value from the provided samples.
        /// Approximately median-unbiased regardless of the sample distribution (R8).
        /// </summary>
        /// <param name="data">The data sample sequence.</param>
        public static double LowerQuartile(this IEnumerable <double> data)
        {
            var array = data.ToArray();

            return(ArrayStatistics.LowerQuartileInplace(array));
        }