## S3 method for class 'uncert':
update(object, expr = NULL, method = NULL, x = NULL, u = NULL, c=NULL,
df = NULL, cov = NULL, cor = NULL, distrib = NULL,
distrib.pars = NULL, delta = NULL, B = NULL, keep.x = NULL, ...)
uncert
.uncert
. See Details for options.uncert$budget$c
No effect except for updates using uncert.default
.u
and cov
should be specified; if both are specified, cov
will take precedence and a warning will be issued.delta
for numeric evaluation methods.B
when updating method="MC"
.keep.x
passed to uncertMC
for Monte Carlo updates.uncert
or uncertMC
method="MC"
of class uncert-class
and uncertMC-class
for details.method
may result in an object of
different class. Updating an "MC"
will return an object of class method="MC"
will return an object of class uncert
such as x
, u
, df
etc. can be specified as named lists, named vectors or arrays, with names corresponding to
names of the input quantities in the uncertainty budget (that is, the names may correspond
to one or more of row.names(uncert$budget)
). If names are present, only the
corresponding individual members are updated.
If names are not present, the complete vector or list in uncert
is replaced, and names added.
Matrix elements cor
and cov
must be specified completely; see
buildCor
, updateCor
and associated functions for
covariance matrices for compact update methods.uncert-class
, uncert-class
, uncertMC
, uncertMC-class
#From uncert:
expr <- expression(a+b*2+c*3+d/2)
x <- list(a=1, b=3, c=2, d=11)
u <- lapply(x, function(x) x/10)
u.expr<-uncert(expr, x, u, method="NUM")
u.expr
update(u.expr, u=list(a=0.3))
update(u.expr, method="MC")
Run the code above in your browser using DataLab