HypothesisTesting {fBasics}R Documentation

Tests Class Representation and Utilities

Description

Class representation and methods for objects of class 'fHTEST'.

The class representation and methods are:

fHTEST Representation for an S4 object of class "fHTEST",
show S4 print method.

Utility Functions:
pPlot General finite sample probability plot,
pTable interpolated probabilities from finite sample table,
qTable interpolated quantiles from finite sample table.

Usage

show.fHTEST(object)

pPlot(X, nN = 100, nStat = 100, logN = TRUE, logStat = FALSE, 
        fill = FALSE, linear = TRUE, digits = 8, doplot = TRUE, ...)
pTable(X, Stat, N, digits = 4)
qTable(X, p, N, digits = 4)

Arguments

digits an integer value with the number of rounding digits.
doplot a logical flag. Should a plot be displayed?
fill [pPlot] -
a logical flag deciding if missing data should be filled with asymptotic values zero and one.
linear [pPlot] -
a logical flag indicating the type of interpolation.
logN, logStat [pPlot] -
two logical flags deciding if the data should be on a logarithmic scale or not.
N an integer value or vector of sample sizes.
nN, nStat [pPlot] -
two integer values with the size of the table.
object [show] -
an S4 object of class "fHTEST".
p a numeric value or vector of probabilities.
Stat a numeric value or vector of quantiles or statistic values.
X [pPlot][*Table] -
a data frame or matrix of a finite sample test table.
... [pPlot] -
additional arguments to be passed.

Value

In contrast to R's output report from S3 objects of class "htest" a different output report is produced. The tests return an S4 object of class "fHTEST". The object contains the following slots:

@call the function call.
@data the data as specified by the input argument(s).
@test a list whose elements contail the results from the statistical test. The information provided is similar to a list object of class{"htest"}.
@title a character string with the name of the test. This can be overwritten specifying a user defined input argument.
@description a character string with an optional user defined description. By default just the current date when the test was applied will be returned.
statistic the value(s) of the test statistic.
p.value the p-value(s) of the test.
parameters a numeric value or vector of parameters.
estimate a numeric value or vector of sample estimates.
conf.int a numeric two row vector or matrix of 95
method a character string indicating what type of test was performed.
data.name a character string giving the name(s) of the data.


The functions pPlot, pTable, and qTable plot and iterpolate finite sample test statistic data from a table. The table is a data frame or a matrix where columns denote the size and rows the probabilities. The column and row names must hold the sizes and probabilities as character strings. The values of the matrix hold the statistic values.

Author(s)

Diethelm Wuertz for the Rmetrics R-port.

Examples

## SOURCE("fBasics.15C-HypothesisTesting")

## fHTEST -
   getClass("fHTEST")

## pPlot -
## jbTable -
   # Interpolated plot of Small Jarque Bera Table:
   X = jbTable(type = "LM", size = "small")
   pPlot(X, linear = TRUE, logStat = TRUE)
   pPlot(X, linear = TRUE, logStat = TRUE, fill = TRUE, main = "JB LM")
   pPlot(X, linear = FALSE, logStat = TRUE)
   pPlot(X, linear = FALSE, logStat = TRUE, fill = TRUE)
    
## [pq]Table -
## jbTable - 
   # Jarque Bera B q and p Table:
   X = jbTable(type = "LM", size = "small")
   p = (1:99)/100
   plot(qTable(X, p, N = 100), p, type = "b")
   Stat = seq(0.01, 15, length = 100)
   plot(Stat, pTable(X, Stat, N = 100), type = "b")  

[Package fBasics version 221.10065 Index]