ks.srm.test: KS test for software reliability models

Description Usage Arguments Value Examples

View source: R/kstest.R

Description

Perform the KS test for the estimated software reliability models

Usage

1
2
3
4
5
6
ks.srm.test(
  obj,
  alternative = c("two.sided", "less", "greater"),
  method = c("mc", "gks", "mc2", "yamada"),
  ...
)

Arguments

obj

An object of an estimated result by Rsrat

alternative

A string indicates the alternative hypothesis and must be one of "two.sided" (default), "less", or "greater".

method

A string indicates the method for KS test with group data. "mc" and "mc2" are Monte-Carlo methods. "gks" is the generalized KS test. "yamada" is an approximation. The default is "mc".

...

A list of other options that are passed to concrete functions.

Value

A list with components;

statistic

A value of the test statistic.

p.value

A value of the p-value of the test.

p.value.lower

A lower bound of the p-value of the test. (gks)

p.value.upper

A upper bound of the p-value of the test. (gks)

alternative

A string of the alternative hypothesis.

b

An integer for the number of resamples. (mc, mc2)

alpha

A value of the significant level. (mc, mc2)

cv

A value of the coefficient variation. (mc, mc2)

lhc

A logical indicates resamples are drawn by Latin hypercude. (mc, mc2)

seed

An integer for the seed of random numbers. (mc, mc2)

Examples

1
2
3
4
5
6
7
data(dacs)
result <- fit.srm.nhpp(time=sys1[sys1>=0],
                       te=-sys1[sys1<0], srm.name=c("exp"))
ks.srm.test(result)
results <- fit.srm.nhpp(time=sys1[sys1>=0],
                        te=-sys1[sys1<0], srm.name=c("exp", "gamma"))
sapply(results, function(x) x$p.value)

SwReliab/gof4srm documentation built on Dec. 18, 2021, 3:05 p.m.