public double Predict(double x) { if (LoessIntervals == null || !LoessIntervals.Any()) { throw new Illumina.Common.IlluminaException("Unable to predict because no intervals are available."); } LoessInterval interval = FindInterval(x); if (interval == null) { throw new Illumina.Common.IlluminaException(String.Format("Unable to find an interval for {0}.", x)); } return(predict(x, interval)); }
private double predict(double x, LoessInterval interval) { var coeffs = LoessInterpolator.computeCoefficients(x, SortedXs, SortedYs, SortedRobustnessWeights, interval.BandwidthInterval); return LoessInterpolator.predict(x, coeffs); }
private double predict(double x, LoessInterval interval) { var coeffs = LoessInterpolator.computeCoefficients(x, SortedXs, SortedYs, SortedRobustnessWeights, interval.BandwidthInterval); return(LoessInterpolator.predict(x, coeffs)); }