ALTAAnalysisResults Class: Difference between revisions

From ReliaWiki
Jump to navigation Jump to search
No edit summary
Line 1: Line 1:
{{Template:APIClass|ALTADataSet Class|ALTADataSet}}
{{Template:API}}{{Template:APIBreadcrumb}}
{{Template:ALTADataSet.AnalysisResults.Cmt}}


In ALTA, this is the '''LK Value''' that can appear in the '''Analysis Summary''' area on the control panel.
Represents the likelihood function value estimated from the accelerated life testing data analysis of an associated [[ALTADataSet Class|ALTADataSet Class]] object.


== Properties==


*LikelihoodValue (as ''double'') {{APIComment|The likelihood function value.}}
== Properties  ==
{| {{APITable}}
|-
| style="width: 180px;"|LikelihoodValue||Gets the likelihood function value (LK value). '''Double'''.
|}


== Usage Example ==


<div style="margin-right: 150px;">
== Example ==
  {{APIComment|'Declare the ALTADataSet. See [[ALTADataSet Constructors]].}}
The following example demonstrates how to return the LK value of a particular ALTADataSet object.
  Dim ALTADS as New ALTADataSet
 
'''VBA'''
  {{APIComment|'Declare a new ALTADataSet object.}}
  {{APIPrefix|Dim}} ADS {{APIPrefix|As New}} ALTADataSet
    
    
  {{APIComment|'Define a single stress. See [[ALTADataSet.AddStressDefinition|AddStressDefinition]].}}
  {{APIComment|'Define a stress type with use stress level &#61; 25.}}
  ALTADS.AddStressDefinition("Stress1", ALTASolverLSR.Exponential, 100)
  {{APIPrefix|Call}} ADS.AddStressDefinition({{APIString|"Stress1"}},,300)
 
  {{APIComment|'Add failure times to the data set. See [[ALTADataSet.AddFailure|AddFailure]]}}
  {{APIComment|'Add failure times for Stress1 &#61; 190.}}
  ALTADS.AddFailure(10, 1, 200)
  {{APIPrefix|Dim}} Stress(0) {{APIPrefix|As}} Variant
  ALTADS.AddFailure(20, 1, 200)
  Stress(0) = 190
  ALTADS.AddFailure(5, 1, 250)
  {{APIPrefix|Call}} ADS.AddFailure(100, 1, Stress)
 
  {{APIPrefix|Call}} ADS.AddFailure(120, 1, Stress)
  {{APIComment|'Fit the data to a model using default analysis settings.}}
  ALTADS.Calculate()
  Stress(0) = 235
  {{APIPrefix|Call}} ADS.AddFailure(130, 1, Stress)
  {{APIPrefix|Call}} ADS.AddFailure(140, 1, Stress)
  {{APIComment|'Fit the data to a model, using all default analysis settings.}}
  {{APIPrefix|Call}} ADS.Calculate()
 
{{APIComment|'Retrieve the LK value.}}
  {{APIPrefix|Dim}} LK {{APIPrefix|As}} Double
  LK = ADS.AnalysisResults.LikelihoodValue
  Msgbox(LK)
 
'''VB.NET'''
{{APIComment|'Declare a new ALTADataSet object.}}
  {{APIPrefix|Dim}} ADS {{APIPrefix|As New}} ALTADataSet
    
    
  {{APIComment|'Retrieve and save the likelihood result value.}}
{{APIComment|'Define a stress type with use stress level &#61; 25.}}
  Dim Likelihood As Double
  ADS.AddStressDefinition({{APIString|"Stress1"}},,300)
  Likelihood = ALTADS.AnalysisResults.LikelihoodValue
</div>
{{APIComment|'Add failure times for Stress1 &#61; 190.}}
  ADS.AddFailure(100, 1, 190)
  ADS.AddFailure(120, 1, 190)
  ADS.AddFailure(130, 1, 235)
  ADS.AddFailure(140, 1, 235)
{{APIComment|'Fit the data to a model, using all default analysis settings.}}
  ADS.Calculate()
 
  {{APIComment|'Retrieve the LK value.}}
  {{APIPrefix|Dim}} LK {{APIPrefix|As}} Double
  LK = ADS.AnalysisResults.LikelihoodValue
  Msgbox(LK)

Revision as of 18:00, 19 April 2016

APIWiki.png


Member of: SynthesisAPI

Represents the likelihood function value estimated from the accelerated life testing data analysis of an associated ALTADataSet Class object.


Properties

Name Description
LikelihoodValue Gets the likelihood function value (LK value). Double.


Example

The following example demonstrates how to return the LK value of a particular ALTADataSet object.

VBA

 'Declare a new ALTADataSet object. 
  Dim ADS As New ALTADataSet
 
 'Define a stress type with use stress level = 25. 
  Call ADS.AddStressDefinition("Stress1",,300)

 'Add failure times for Stress1 = 190. 
  Dim Stress(0) As Variant
  Stress(0) = 190
  Call ADS.AddFailure(100, 1, Stress)
  Call ADS.AddFailure(120, 1, Stress)

  Stress(0) = 235
  Call ADS.AddFailure(130, 1, Stress)
  Call ADS.AddFailure(140, 1, Stress)

 'Fit the data to a model, using all default analysis settings. 
  Call ADS.Calculate()
  
 'Retrieve the LK value. 
  Dim LK As Double
  LK = ADS.AnalysisResults.LikelihoodValue
  Msgbox(LK)
VB.NET

 'Declare a new ALTADataSet object. 
  Dim ADS As New ALTADataSet
 
 'Define a stress type with use stress level = 25. 
  ADS.AddStressDefinition("Stress1",,300)

 'Add failure times for Stress1 = 190. 
  ADS.AddFailure(100, 1, 190)
  ADS.AddFailure(120, 1, 190)
  ADS.AddFailure(130, 1, 235)
  ADS.AddFailure(140, 1, 235)

 'Fit the data to a model, using all default analysis settings. 
  ADS.Calculate()
  
 'Retrieve the LK value. 
  Dim LK As Double
  LK = ADS.AnalysisResults.LikelihoodValue
  Msgbox(LK)