edu.ucla.stat.SOCR.distributions
Class WeibullDistribution

java.lang.Object
  extended by edu.ucla.stat.SOCR.core.SOCRValueSettable
      extended by edu.ucla.stat.SOCR.core.Distribution
          extended by edu.ucla.stat.SOCR.distributions.WeibullDistribution
All Implemented Interfaces:
IValueSettable, Pluginable, java.util.Observer

public class WeibullDistribution
extends Distribution

This class models the Weibull distribution with specified shape and scale parameters. http://mathworld.wolfram.com/WeibullDistribution.html .


Field Summary
 
Fields inherited from class edu.ucla.stat.SOCR.core.Distribution
applet, CONTINUOUS, DISCRETE, MAXMGFXVAL, MAXMGFYVAL, MINMGFXVAL, MIXED, name
 
Constructor Summary
WeibullDistribution()
          This default constructor creates a new Weibull distribution with shape parameter 1 and scale parameter 1
WeibullDistribution(double k, double b)
          This general constructor creates a new Weibull distribution with spcified shape and scale parameters
 
Method Summary
 double getCDF(double x)
          This method computes the cumulative distribution function
 double getDensity(double x)
          This method compues teh denstiy function
 double getFailureRate(double x)
          This method computes the failure rate function
 double getMaxDensity()
          This method returns the maximum value of the getDensity function
 double getMean()
          The method returns the mean
 java.lang.String getOnlineDescription()
          This method returns an online description of this distribution.
 double getQuantile(double p)
          This method returns the getQuantile function
 double getScale()
          This method returns the scale parameter
 double getShape()
          This method returns the shape parameter
 double getVariance()
          This method returns the variance
 void initialize()
          used for some subclass to initialize before being used
 void setParameters(double k, double b)
          This method sets the shape and scale parameter.
 void setScale(double b)
          This method sets the shape parameter
 void setShape(double k)
          This method sets the shape parameter
 void valueChanged()
           
 
Methods inherited from class edu.ucla.stat.SOCR.core.Distribution
addObserver, betaCDF, comb, factorial, findGFRoot, findRoot, gamma, gammaCDF, getDisplayPane, getDomain, getGFDerivative, getGFSecondDerivative, getInstance, getLocalHelp, getMean, getMedian, getMGF, getMgfDomain, getName, getPGF, getPGFDomain, getSampleMoment, getSD, getSOCRDistributionFunctors, getSOCRDistributions, getType, getVariance, inverseCDF, logGamma, paramEstimate, perm, sampleMean, sampleVar, setApplet, setDomain, setDomain, setMGFDomain, setMGFDomain, setMGFParameters, setMGFParameters, setMGFParameters, setMGFParameters, setParameters, setPGFDomain, setPGFDomain, setPGFParameters, setPGFParameters, setPGFParameters, setPGFParameters, simulate, update, valueChanged
 
Methods inherited from class edu.ucla.stat.SOCR.core.SOCRValueSettable
createComponentSetter, createValueSetter, createValueSetter, createValueSetter, createValueSetter, getComponentSetter, getComponentSetters, getValueSetter, getValueSetters
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

WeibullDistribution

public WeibullDistribution(double k,
                           double b)
This general constructor creates a new Weibull distribution with spcified shape and scale parameters


WeibullDistribution

public WeibullDistribution()
This default constructor creates a new Weibull distribution with shape parameter 1 and scale parameter 1

Method Detail

initialize

public void initialize()
Description copied from class: Distribution
used for some subclass to initialize before being used

Overrides:
initialize in class Distribution

valueChanged

public void valueChanged()
Overrides:
valueChanged in class Distribution

setParameters

public void setParameters(double k,
                          double b)
This method sets the shape and scale parameter. The normalizing constant is computed and the default interval defined


getDensity

public double getDensity(double x)
This method compues teh denstiy function

Specified by:
getDensity in class Distribution

getMaxDensity

public double getMaxDensity()
This method returns the maximum value of the getDensity function

Overrides:
getMaxDensity in class Distribution

getMean

public double getMean()
The method returns the mean

Overrides:
getMean in class Distribution

getVariance

public double getVariance()
This method returns the variance

Overrides:
getVariance in class Distribution

getCDF

public double getCDF(double x)
This method computes the cumulative distribution function

Overrides:
getCDF in class Distribution

getQuantile

public double getQuantile(double p)
This method returns the getQuantile function

Overrides:
getQuantile in class Distribution

getFailureRate

public double getFailureRate(double x)
This method computes the failure rate function

Overrides:
getFailureRate in class Distribution

getShape

public double getShape()
This method returns the shape parameter


setShape

public void setShape(double k)
This method sets the shape parameter


getScale

public double getScale()
This method returns the scale parameter


setScale

public void setScale(double b)
This method sets the shape parameter


getOnlineDescription

public java.lang.String getOnlineDescription()
This method returns an online description of this distribution.

Overrides:
getOnlineDescription in class Distribution