Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## org.statcato.statistics.inferential
Class HypothesisTest1MeanSigmaUnknown

    java.lang.Object
      org.statcato.statistics.inferential.HypothesisTest1MeanSigmaUnknown

    public class HypothesisTest1MeanSigmaUnknown

extends java.lang.Object

A hypothesis test for 1 population mean, population standard deviation unknown.

Since:
  1.0
Version:
  %I%, %G%
Author:
  Margaret Yau

Constructor Summary
`HypothesisTest1MeanSigmaUnknown(int n, double mu, double s, double confidenceLevel, int testType)` Constructor.

Method Summary
`java.lang.String` | `criticalValue()` Returns the critical value corresponding to the given confidence level and type of test.
`double` | `pValue(double xBar)` Returns the p-value corresponding to xBar in a t distribution.
`double` | `testStatistics(double xBar)` Returns the test statistics for the given sample mean xBar.

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Constructor Detail

### HypothesisTest1MeanSigmaUnknown

    public HypothesisTest1MeanSigmaUnknown(int n,
                                           double mu,
                                           double s,
                                           double confidenceLevel,
                                           int testType)

  Constructor.

  Parameters:
    `n` - sample size
    `mu` - hypothesized mean
    `s` - sample standard deviation
    `confidenceLevel` - confidence level
    `testType` - (as defined in `HypothesisTest`)

Method Detail

### testStatistics

    public double testStatistics(double xBar)

  Returns the test statistics for the given sample mean xBar.

  t = (xBar - mu) / (s / sqrt(n))

  Parameters:
    `xBar` - sample mean
  Returns:
    test statistic z score

### criticalValue

    public java.lang.String criticalValue()

  Returns the critical value corresponding to the given confidence level and type of test. Uses the t distribution.

  Returns:
    critical value
  See Also:
    `HypothesisTest`

### pValue

    public double pValue(double xBar)

  Returns the p-value corresponding to xBar in a t distribution.

  Parameters:
    `xBar` - x bar
  Returns:
    p-value p-Value corresponding to xBar

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD