Accord.Controls.DataSeriesBox.show C# (CSharp) Method

show() private static method

private static show ( String title, double>.Func function, double min, double max, double step, int npoints ) : DataSeriesBox
title String
function double>.Func
min double
max double
step double
npoints int
return DataSeriesBox
        private static DataSeriesBox show(String title, Func<double, double> function, double? min, double? max, double? step, int? npoints)
        {
            if (min == null || max == null)
            {
                DoubleRange range;
                if (ScatterplotBox.GetRange(function, out range))
                {
                    min = range.Min;
                    max = range.Max;
                }
                else
                {
                    min = 0;
                    max = 1;
                }
            }

            if (npoints == null)
                npoints = 1000;

            if (step == null)
                step = (max - min) / npoints;

            double[] input = Vector.Interval(min.Value, max.Value, step.Value);
            double[] output = Matrix.Apply(input, function);

            return show(title, input, new[] { output });
        }

Same methods

DataSeriesBox::show ( String title, IEnumerable x, IEnumerable series, bool time = false ) : DataSeriesBox
DataSeriesBox::show ( String title, double x, double series, bool time = false ) : DataSeriesBox