| profile.samediff {sensR} | R Documentation |
Computes the (normalized or relative) profile likelihood for the parameters of a same-different test, plots the normalized profile likelihood and computes profile likelihood confidence intervals.
## S3 method for class 'samediff':
profile(fitted, which = 1:2, max = 2, numpts = 100,
max.delta = 10, max.tau = 10, ...)
## S3 method for class 'profile.samediff':
plot(x, which = 1:nc, level = c(0.99, 0.95),
fig = TRUE, ...)
## S3 method for class 'samediff':
confint(object, parm = c("tau", "delta"), level = 0.95, max = c(10, 10)
, ...)
fitted |
a samediff object |
x |
a profile.samediff object |
object |
a samediff object |
which |
numeric: which parameters to profile or plot; either "1" or "2" or "1:2" to mean "tau", "delta" or both respectively. |
parm |
the parameter(s) to compute the confidence interval for |
max |
for profile: control parameter to specify how many units beyond the MLE,
the profiling should proceed. For confint: control parameter,
that can control the convergence for especially very large delta |
numpts |
control parameter: At how many points should the profile likelihood be evaluated? |
max.delta |
control parameter: The maximum point at which to evaluate the profile likelihood for delta |
max.tau |
same as max.delta for "tau". |
level |
for plot: At which levels to include horizontal lines to indicate
confidence levels in plots of the normalized profile
likelihoods. For confint: at which level to compute the
confidence interval. |
fig |
logical: Should the normalized profile likelihoods be plotted? |
... |
not currently used. |
For profile:
An object of class "profile.samediff", "data.frame"—a
data.frame with two columns for each parameter profiled giving
the value of the parameter and the corresponding value of the profile
likelihood.
For plot:
An object of class "nProfile.samediff", "data.frame"—the
data.frame from the profile-object with extra
columns corresponding to the which parameter containing the
normalized profile liklelihood.
For confint:
A 2x2 matrix with columns named "lower", "upper" giving the
lower and upper (1 - alpha)% confidence interval for the
parameters named in the rows.
Rune Haubo B Christensen
# data: 8 of the same samples were judged to be same # 5 of the same samples were judged to be different # 4 of the different samples were judged to be same # 9 of the different samples were judged to be different sadi <- samediff(8, 5, 4, 9) confint(sadi) plot(profile(sadi))