WeibullDataSet.CalculateBestFit: Difference between revisions

From ReliaWiki
Jump to navigation Jump to search
No edit summary
Line 1: Line 1:
{{Template:APIClass|WeibullDataSet Class|WeibullDataSet}}
{{Template:APIClass|WeibullDataSet Class|WeibullDataSet}}
== Declaration  ==
 
{{APIPrefix|Sub}}
Runs the calculation and finds a distribution model that best fits the data in the WeibullDataSet.
 
== Method Syntax==
{{APIName|CalculateBestFit()}}
{{APIName|CalculateBestFit()}}


{{APIComment|Finds the distribution that fits the data best. Sets Fitted Model property if successful. Clears it (sets to Nothing) in case of an error.}}
{{APIComment|Finds the distribution that fits the data best. Sets Fitted Model property if successful. Clears it (sets to Nothing) in case of an error.}}
== Usage Example ==
{{APIComment|Declare the WeibullDataSet. See [[New WeibullDataSet]] for additional details.}}
        Dim WDS as New WeibullDataSet
{{APIComment|Add values to the raw data. See [[WeibullDataSet.AddFailure]] for additional details.}}
        WDS.AddFailure(1, 1)
        WDS.AddFailure(2, 1)
        WDS.AddFailure(3, 1)
{{APIComment|Calculate the Fitted Model using the raw data.}}
        WDS.CalculateBestFit
{{APIComment|Use the Fitted Model using the raw data.}}
        Dim WDSFittedModel as cModel
        WDSFittedModel = WDS.FittedModel

Revision as of 20:45, 11 September 2013



Runs the calculation and finds a distribution model that best fits the data in the WeibullDataSet.

Method Syntax

CalculateBestFit()

Finds the distribution that fits the data best. Sets Fitted Model property if successful. Clears it (sets to Nothing) in case of an error.

Usage Example

Declare the WeibullDataSet. See New WeibullDataSet for additional details.

       Dim WDS as New WeibullDataSet

Add values to the raw data. See WeibullDataSet.AddFailure for additional details.

       WDS.AddFailure(1, 1)
       WDS.AddFailure(2, 1)
       WDS.AddFailure(3, 1)

Calculate the Fitted Model using the raw data.

       WDS.CalculateBestFit

Use the Fitted Model using the raw data.

       Dim WDSFittedModel as cModel
       WDSFittedModel = WDS.FittedModel