Description Usage Arguments Details Value Abrem options To Do Note Author(s) See Also Examples
This function handles the various calculation, printing and plotting options of the abrem package.
1 |
... |
Options for calculating, printing and plotting with the abrem package. |
This function borrows its internal structure from
the par function of package graphics.
It can be used in different ways:
options.abrem()
Returns the currently used options and there values.
options.abrem()$dist
options.abrem("dist")
Returns the current value of an option.
options.abrem(cl=0.95)
options.abrem(list(cl=0.95,S=5e4))
Sets the specified options.
Currently, there is no way to reset the options to the default values using this function. One might, before changing any options, store the option list in a temporary variable like
abrem.defaults <- options.abrem()
for restoring it later by running options.abrem(abrem.defaults).
The function creates a globally accessible list named options_abrem,
holding the options. One should always use the options.abrem
function to access the option list, do not access this list directly.
Executing options.abrem without arguments returns a named list
containing the currently active global options of the abrem package.
When arguments were supplied, these are returned in a named list.
cex.pointsA number describing the relative size of the datapoint glyphs.
Defaults to 1.
clConfidence level: A single number from the interval [0,[1
specifying the confidence level for various confidence calculations.
Defaults to 0.9.
colAn integer or character string describing the color of a
graphical entity.
See function colors for available colors.
Defaults to "black".
col.gridAn integer or character string describing the color of the grid
Defaults to "gray".
conf.blives.sidesEither "lower", "upper" or "double",
specifying the type of bound(s) to be calculated.
Defaults to c("double").
conf.whatA vector of class "character" describing for which entities
that confidence should be calculated.
Defaults to c("blives").
coordinate.text.sizeA number determining the relative coordinate text label size.
Defaults to 0.7.
distA character string with the distribution target for fitting.
See abrem.fit for in-depth discussion of the settings.
Defaults to "weibull".
in.legendLogical value controlling the inclusion of various elements in
the legend. See abrem.fit and abrem.conf
for more details.
Defaults to TRUE.
in.legend.blivesLogical value controlling the inclusion of B-life confidence bounds in the legend.
Defaults to TRUE.
in.legend.gofLogical value controlling the inclusion of goodness-of-fit
indicators in the legend. Note that this does not prohibit
calculation of sometimes time consuming prr values, it only
prevents inclusion in the legend.
Defaults to TRUE.
is.plot.cbLogical value controlling the plotting of various types of
confidence bounds (if any present in the abrem object).
Defaults to TRUE.
is.plot.fitLogical value controlling the plotting of the fitted line.
Defaults to TRUE.
is.plot.gridLogical value controlling the plotting of the grid.
Defaults to TRUE.
is.plot.legendLogical value controlling the plotting of the legend.
Defaults to TRUE.
is.plot.ppLogical value controlling the plotting of the (life-)time observations' probability plot positions.
Defaults to TRUE.
labelA character string with the title of the legend box, can be used to label a dataset or fit.
Defaults to NULL.
legend.text.sizeA number determining the relative legend text size.
Defaults to 0.7.
logA character string describing the type of plotting canvas to use.
Possible values are "x" (Weibull canvas), "xy"
(Lognormal canvas), "" (Weibull Y axis, linear X axis)
and "y" (Lognormal Y axis, linear X axis).
Defaults to "x", Weibull canvas.
For contour plots, log is always "" and cannot be set.
ltyAn integer describing the line type of both the fitted
line and the confidence bounds, if any.
See function par for available line types.
Defaults to 1.
lwdAn integer describing the line width of both the fitted line and the confidence bounds, if any.
Defaults to 2.
lwd.pointsAn integer describing the thickness of the datapoint glyphs.
Defaults to 2.
main, main.contourA character string; the main title of the plot or contour plot.
Defaults to "Probability Plot" or "Contour Plot" .
marA numerical vector of the form c(bottom, left, top, right)
which gives the number of lines of margin to be specified on
the four sides of the plot.
See function par for more info.
Defaults to c(5.1,4.1,5.1,2.1).
method.conf.blivesA vector of class "character" describing the techniques used
for calculating confidence for B-lives.
See abrem.conf for in-depth discussion of the settings.
Defaults to c("mcpivotals").
method.fitA vector of class "character" with fitting options.
See abrem.fit for in-depth discussion of the settings.
Defaults to c("rr","xony").
pchAn integer or single character describing the plotting symbol, used for
plotting the datapoints. For more info, see
points.
Defaults to 1.
persistentExperimental parameter, do not use.
Defaults to TRUE.
pivotalsCurrently unused. Defaults to FALSE.
pppp is short for "probability plot positions", it is a vector of
class "character" describing the type of plot positions to be
calculated.
Possible values are "median" (exact median plot postions
calculated using the Incomplete Beta function) and "benard"
(a good approximation to the median plot positions). Both options
can be supplied at the same time but currently, only the first
element in the pp vector will be used for
further fitting by abrem.fit
Currently, there are no plans to implement
"hazen" and "mean" plotting positions.
Defaults to c("median").
SAn integer describing the number of Monte Carlo simulations on
which the Monte Carlo pivotal confidence bounds and calculation
of the "prr" goodness-of-fit indicator are based (See
prrVal of package pivotals for more
details).
Defaults to 10000.
signifAn integer describing the significant digits of various numbers that are displayed in the legend.
Defaults to 4.
sub, sub.contourA character string; the subtitle of the plot or contour plot.
Defaults to "".
thresholdA logical value specifying whether a threshold time value should be
substracted from the graphical elements before plotting. This is
particulary useful when fitting three parameter models like
weibull3p, where the third model parameter is a threshold value.
If TRUE, the software will subtract the threshold value
(that is to be calculated by abrem.fit) from its
associated graphical
elements like plot poistions, fits and confidence bounds.
If a numeric value is passed, the software will subtract this value from the appropriate graphical elements.
Note: currently, "threshold" should only be used in combination with
Abrem and abrem.fit and not with
plot.abrem. See abrem.fit for more info.
Defaults to FALSE
unrelAn unordered numeric vector with unreliability levels for which B-life confidence will be calculated.
Defaults to c(0.1,0.05,0.01).
unrel.nAn integer controlling the amount of unreliability levels for
which confidence bounds are calculated and ultimately plotted.
See abrem.conf for more details.
Defaults to 25
verbosityAn integer from c(1,2,3) setting the level of verbosity of
all abrem functions. Use this for debugging.
Defaults to 1.
xlab, ylabCharacter strings with the labels for the X and Y axis.
Default to "Time To Failure" and
"Unreliability [%]" respectively.
For contour plots, Default to "Eta" and "Beta" respectively.
xlimA numeric vector with two values determining the plotting range
of the horizontal axis of the plot.
plot.abrem calculates horizontal limits automatically
from its data argument.
Defaults to NULL.
ylimA numeric vector with two values determining the plotting range
of the vertical axis of the plot. Allowed values come
from the interval ]0,1[. plot.abrem calculates
vertical limits automatically from its data argument; if vertical
plotting positions do not exceed the standard range of
c(0.01,0.99), then the latter is used.
Otherwise, the standard range is expanded to include the
extreme plot positions.
The standard vertical range is currently hardcoded to c(0.01,0.99).
Defaults to NULL.
Add the possibility to reset to the default values.
Implement returning of the pivotals dataframe in the
abrem object.
Add detection of unsupported arguments.
Typical usage of abrem involves calling a sequence of functions like:
da <- Abrem(c(10,11,27))
da <- abrem.fit(da)
da <- abrem.conf(da)
plot(da)
Do not call options.abrem in between these functions because some
options are locked and cannot be altered further in this chain. This is an
implication of the way the abrem object is structured.
The correct time to specify an option is when it is needed for the first
time. For example, when the color setting option col = "red" is
passed as an argument of function Abrem, it will be used for
datapoints, fits and confidence bounds. If supplied to abrem.conf,
only the confidence bounds will have the specified color, hereby overriding
any previously inherited color settings from abrem.fit
or Abrem.
Jurgen Symynck jusy@openreliability.org
Abrem,
abrem.fit,
abrem.conf,
plot.abrem
1 2 3 4 5 6 7 8 9 10 11 12 13 | ## backup options ##
abrem.defaults <- options.abrem()
## setting new options ##
options.abrem(S=5e5,cl=0.99)
## listing options ##
options.abrem()
options.abrem()$main
## restore options ##
options.abrem(abrem.defaults)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.