PDFModeler

class PDFModeler(observations: DoubleArray, scoringModels: Set<PDFScoringModel> = defaultScoringModels)

Parameters

observations

the data to analyze for fitting a probability distribution

scoringModels

the scoring models to use to evaluate the fitting process and recommend a distribution. By default, this is defaultScoringModels

Constructors

Link copied to clipboard
constructor(observations: DoubleArray, scoringModels: Set<PDFScoringModel> = defaultScoringModels)

Types

Link copied to clipboard
object Companion

Properties

Link copied to clipboard

How close we consider a double is to 0.0 to consider it 0.0 Default is 0.001

Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard

Estimates a possible shift parameter for the data. See PDFModeler.estimateLeftShiftParameter(). If any of the data are negative then there will be no shift. There must be at least 3 different positive values for a shift to be estimated; otherwise, it will be 0.0. Any estimated shift that is less that the defaultZeroTolerance will be set to 0.0.

Link copied to clipboard
Link copied to clipboard

Functions

Link copied to clipboard
fun bootStrapParameterEstimates(result: EstimationResult, numBootstrapSamples: Int = 399, level: Double = 0.95, stream: RNStreamIfc = KSLRandom.nextRNStream()): List<BootstrapEstimate>
fun bootStrapParameterEstimates(estimator: MVBSEstimatorIfc, numBootstrapSamples: Int = 399, level: Double = 0.95, stream: RNStreamIfc = KSLRandom.nextRNStream(), label: String? = null): List<BootstrapEstimate>

Computes bootstrap confidence intervals for the estimated parameters of the distribution

Link copied to clipboard
fun confidenceIntervalForMinimum(numBootstrapSamples: Int = 399, level: Double = 0.95): Interval

Uses bootstrapping to estimate a confidence interval for the minimum

Link copied to clipboard
fun estimateAndEvaluateScores(estimators: Set<ParameterEstimatorIfc> = allEstimators, automaticShifting: Boolean = true): PDFModelingResults

This function estimates the parameters based on the supplied estimators and scores the estimators based on the supplied scoring models scoringModels. By default, a shift parameter for the distributions is estimated. The results are bundles up into a class that holds the estimation results, the scoring results, and the model used for evaluating the model goodness of fit.

Link copied to clipboard
fun estimateParameters(estimators: Set<ParameterEstimatorIfc>, automaticShifting: Boolean = true): List<EstimationResult>

Estimates the parameters for all estimators represented by the set of estimators. The parameter automaticShifting controls whether the data will be automatically shifted.

fun estimateParameters(estimator: ParameterEstimatorIfc, automaticShifting: Boolean = true): EstimationResult

A convenience method for invoking parameter estimation for a single instance of ParameterEstimatorIfc. The parameter automaticShifting controls whether the data will be automatically shifted.

Link copied to clipboard

This function applies the supplied scoring models to the estimation results.

Link copied to clipboard
fun evaluateScoringResults(scoringResults: List<ScoringResult>, rankingMethod: Statistic.Companion.Ranking = defaultRankingMethod, model: AdditiveMODAModel = createDefaultPDFEvaluationModel(scoringResults, rankingMethod)): AdditiveMODAModel

Evaluates the supplied scoring results using the supplied evaluation model. A default additive MODA model is supplied that uses linear value functions for each metric.

Link copied to clipboard
fun htmlACFPlot(plotFileName: String? = null): String

The ACF plot portion of the results as html. The optional argument plotFileName can be used to cause a PNG file to be saved to the plot directory.

Link copied to clipboard
fun htmlGoodnessOfFitSummary(pdfModelingResults: PDFModelingResults, evaluationMethod: EvaluationMethod = EvaluationMethod.Scoring, plotFileName: String? = null): String

Produces a html representation of the goodness of fit results which include the distribution fit quad plot and the chi-squared goodness of fit statistics.

Link copied to clipboard
fun htmlHistogram(plotFileName: String? = null): String

The histogram portion of the results as html. The optional argument plotFileName can be used to cause a PNG file to be saved to the plot directory.

Link copied to clipboard
fun htmlObservationPlot(plotFileName: String? = null): String

The observations plot portion of the results as html. The optional argument plotFileName can be used to cause a PNG file to be saved to the plot directory.

Link copied to clipboard
fun htmlScoringSummary(pdfModelingResults: PDFModelingResults, rankingMethod: Statistic.Companion.Ranking = defaultRankingMethod): String

Produces a html representation of the scoring and metric evaluation results including the recommended distribution.

Link copied to clipboard

Presents a statistical summary of the data in html format. This includes that summary statistics, box plot statistics, histogram statistics, and an analysis of the shift parameter.

Link copied to clipboard

Presents the histograms, box plot, observation plot, and auto-correlation plot for the data.

Link copied to clipboard

Estimation results in the list of results are scored by each scoring model in the supplied set scoring models. Any estimation results within the supplied list that were not successfully estimated or had no parameters estimated will not be scored. The returned list contains instances holding the scoring results for each successfully estimated distribution.

Link copied to clipboard
fun showAllResultsInBrowser(estimators: Set<ParameterEstimatorIfc> = allEstimators, automaticShifting: Boolean = true, pdfModelingResults: PDFModelingResults = estimateAndEvaluateScores(estimators, automaticShifting), rankingMethod: Statistic.Companion.Ranking = defaultRankingMethod, evaluationMethod: EvaluationMethod = EvaluationMethod.Scoring, statResultsFileName: String = "PDF_Modeling_Statistical_Summary", visualizationResultsFileName: String = "PDF_Modeling_Visualization_Summary", scoringResultsFileName: String = "PDF_Modeling_Scoring_Summary", goodnessOfFitResultsFileName: String = "PDF_Modeling_GoodnessOfFit_Summary")

This function will apply the estimators to the data and report all the results in HTML format.