(first two numbers of package versions do not necessarily reflect
package-individual development, but rather are chosen for the
distrXXX family as a whole in order to ease updating "depends"
information)
##############
v 2.8.2
##############
under the hood:
inserted some ## IGNORE_RDIFF_BEGIN comments to prevent NOTES when comparing R.out.save to
R.out on varying architectures, e.g. Rblas/ATLAS
##############
v 2.8.1
##############
user-visible CHANGES:
revised code to delete fuzz when checking the centering/consistency of L2deriv varying from
-- relative accuracy is now determined by the size of FI
under the hood:
introduce S3 class "relMatrix" (and S3 method print.relMatrix) to capture the fact that when
computing relative differences in consistency matrices, some entries in the denominator may
be 0; in order to avoid output of Inf / NaN we catch the output and replace such entries
by "."
##############
v 2.8
##############
user-visible CHANGES:
require more recent versions of distr, distrEx
plot methods now return an S3 object of class \code{c("plotInfo","DiagnInfo")}, i.e., a list containing the
information needed to produce the respective plot, which at a later stage could be used by different graphic engines (like, e.g.
\code{ggplot}) to produce the plot in a different framework. A more detailed description will follow in a subsequent version.
DESCRIPTION tag SVNRevision changed to VCS/SVNRevision
"cleverer parsing of dots" in M[L,C,D]Estimator:
Triggered by an error observed by Kornelius Rohmeyer, we now parse the dots (...) argument
of M[L,C,D]Estimator a little more closely and filter out obvious clashes: We filter out taboo arguments
(causing clashes with formals in optim/optimize and calling arguments); from the remaining ones only
[exactly] named arguments of the optimizer (optim/optimize) and those matching either exactly arguments
of the criterion or all remaining ones (if ... is a formal of the criterion) are passed on:
This way, one can, if desired, do evaluation-wise validity checks in the criterion.
For diagnostic purposes, MCEstimate-class gains a slot optimReturn (of class "ANY" and filled by
NULL by default) which is filled by the return value of the optimizer in "mceCalc" -- it has a
corresponding accessor
distinguish three cases for CvMMDEstimator selected by argument muDatOrMod = c("Dat","Mod", "Other"):
in case "Dat", mu = emp. cdf (default), in case "Mod", mu = current best fit model distribution,
and in case "Other" one has to supply an integration probability mu.
=> consistency between estimate and asyCov
added some theory/references to help file to MD estimators
the L2derivatives of the SimpleL2ParamFamilies and the L2GroupFamilies now respect
restrictions in the support of the underlying distribution: the L2derivatives are 0
whenever the argument x has liesInSupport(distribution,x, checkFin = TRUE) == FALSE
(i.e., in discrete distiributions, with a more refined version, extending the checking
of the numerically truncated support).
new model classes / generators LogisticLocationScaleFamily, CauchyLocationFamily
changed default for CvMMDEstiamtor to variant "Mod" (consistent to fitdistrplus)
more precise / explicit description of the requirements of slots L2deriv and L2deriv.fct in
the help files to generator L2ParamFamily and to L2ParamFamily-class.
E() methods with signature(object = "L2ParamFamily" , ...) gain argument diagnostic
(like E()-methods in distrEx v 2.8.0)
bug fixes
discovered some issues with local variables in L2Families (global values were used instead...)
default for asCov of CvMMDEstimator was inconsistent: the estimator was using emp.cdf, but
the asyCov was using mu the current best fit model distribution
in the wrappers to MDEstimator: CvMMDEstimator, KolmogorovMDEstimator, TotalVarMDEstimator,
HellingerMDEstimator, we had the "wrong" call in slot estimate.call
show-method for ParamWithShapeFamParameter and MCEstimate did unnecessary casting to superclasses
hence hid the true class
argument distance did not show it came from CvMDist, CvMDist2 via CvMMDEstiamtor when unparsed --
now the unparsed argument in CvMMDEstimator is called CvMDist0 so shows that it is related to
CvMDist
in fam.fall to NbinomFamily (with two parameters ) we had matrix(Tr, dimnames = DN) without
specifying nrow and ncol
logical of length>1 in if-clause in trafoEst()
under the hood:
As this is more for internal purposes, example code for the parsing of dots argument
is in lines ll 275--334 in mleCalc-methods.R (wrapped in a if(FALSE){ }).
in code in SimpleL2ParamFamilies.R:
param.0 denotes the local current parameter of the L2Family
param is used as function argument
.0 is used in .fct - functions as local variant (intern to fct) of the current parameter
in the substituted L2deriv.fct, we use .1 which is substituted for .0
in case .0 is already used otherwise (as in NbinomMeanSizeFamily) we use .00 instead
replaced integration for AbscontDistribution(s) in .CvMMDCovariance by integration on quantile scale
=> CvMMDEstimator now works with variances even for Gamma distributions for shape < 1 ...
tuned .CvMMDCovariance() in asCvMVarianceQtl.R for speed (like with kStepEstimator timings are
taken in comment ##-t-##) as the function .CvMMDCovariance was much slower than
.oldCvMMDCovariance for Generalized EVD with Mu Unknown... / now they are at equal there
revised .CvMMDCovariance() to get more performant for discrete distributions /
-> thereby corrected an error in the intermediate formulae, which by
centering/standarizing of the IC in the end already cancelled out beforehand...
but now we are more accurate as to differences in the integration measure mu
and the model distribution (important for integration w.r.t. emp. measure)
the revised .CvMMDCovariance() uses vectorization in evaluation of random variables
and, wherever possible in integration; for the latter, this can be suppressed by
an argument useApply=TRUE through the ... argument
in addition .CvMMDCovariance() now has argument "diagnostic" (like E())
and in calls to E(), the "..." argument is filtered
.process.meCalcRes gains arg "x" to be able to pass on emp.CDF for mu in CvMMDEstimator
if arg asvar.fct of MCEstimator has "x" in formals the observations x are passed on to asvar.fct,
otherwise they are not; correspondingly "x" is passed on to .process.meCalcRes in
MCEstimator(), MDEstimator(), MLEstimator().
old .CvMMDCovariance() becomes .oldCvMMDCovariance
new wrapper .CvMMDCovarianceWithMux which uses emp cdf as mu
new wrappe CvMDist2 which by default uses model distribution as mu
CvMMDEstimator gains argument muDatOrMod = c("Dat","Mod") to distinguish two cases
moved code to .[old]CvMMDCovariance from 0distrModUtils.R to new file asCvMVarianceQtl.R
some fiddeling with the names of MCEstimators:
all functions MDEstimator, CvMMDEstimator, KolmogorovMDEstimator, TotalVarMDEstimator,
HellingerMDEstimator, MLEstimator, MCEstimator gain an extra argument nmsffx for
potential suffices to be appended to the estimator name.
in MDEstimator with Cramer von Mises distance in case
distance == CvMDist2 -> "( mu = model distr. )"
is appended to the default estimator name
similarly in wrapper CvMMDEstimator in case argument 'muDatOrMod' is matched to
muDatOrMod=="Dat" -> "( mu = emp. cdf )"
muDatOrMod=="Mod" -> "( mu = model distr. )"
muDatOrMod=="Other" -> "( mu = )"
is appended to the default estimator name
based on this tag "( mu = ... )" later on, in pkg RobAStBase, a (conditional)
coerce method produces the pIC of the MDE by means of .CvMMDCovariance[WithMux]
new subclasses "MLEstimate", "MDEstimate", "CvMMDEstimate" for internal method dispatch
(robust) start parameters for Nbinom family with two parameters
(robust) start (search) parameters for Poisson family
now specified that we want to use distr::solve
E() methods with signature(object = "L2ParamFamily" , ...) use filtering of dots arguments
(like E()-methods in distrEx v 2.8.0)
E methods with signature(object = "L2ParamFamily" , ...) if (diagnostic==TRUE) return
diagnostic attributes of S3 class "DiagnosticClass"
.CvMMDCovariance() if (diagnostic==TRUE) returns diagnostic attributes of S3 class
"DiagnosticClass"
new wrapper to MDEstimator: CvMMDEstimator, KolmogorovMDEstimator, TotalVarMDEstimator,
HellingerMDEstimator
exported .CvMMDCovariance in distrMod
added call to return value of qqplot
qqplot and returnlevelplot have adopted the same argument naming (and selection paradigm)
as the other diagnostic plots (IC-plot, comparePlot, infoPlot) in pkg RobAStBase:
the suffix is .lbs instead of .lbl,
changed argument name withLab to with.lab
the attributes of shown points have ending .pts
the observations are classed into three groups:
- the labelled observations selected through which.lbs and which.Order
- the shown non labelled observations (which are not in the previous set)
selected by which.nonlbs
- the non-shown observations (the remaining ones not contained in the former 2 grps)
-> point attributes may either refer to prior selection or to post-selection in
which case we have .npts variants
returnlevelplot now accepts a log argument for the y axis (helpful for Pareto distributions, see script...)
under the hood:
wherever possible also use q.l internally instead of q to
provide functionality in IRKernel
fixed omegahat.net issue (raised by K.Hornik,(24.10.2016, 18:08)
bug fixes:
Estimate method for returnlevelplot was passing the wrong xlab
the selection mechanism had to be revised (lacked a passage through ranks)
##############
v 2.6
##############
user-visible CHANGES:
title changed to title style / capitalization
introduced dropZeroDensity argument to ML estimators
arguments panel.first, panel.last for plot-methods can now be lists
introduced returnlevelplot, a generalization of the respective
diagnostic plot facility of package ismev
qqplot and returnlevelplot gain pattern substitution like plot in
titles and x/y axis lables
pattern substitution can now be switched on and off in all plot
functions according to argument withSubst
GENERAL ENHANCEMENTS:
under the hood:
zero dropping (see argument 'dropZeroDensity' above)
--Optimizers like optim require finite values, so get problems when
negative loglikelihood is evaluated, so optionally, and by default,
values with density/likelihood 0 are dropped from optimization
removed ::: internal dependencies (within distr-Fam of pkgs) by copying
respective routines
qqplot:
(already there for a while) gains ability to interchange x- and y-
axis by argument 'datax' for compatibility with other qqplots
gains new methods for object of class "Estimate" (which could also be
seen as "fitted" objects...)
additional argument added.points.CI to allow for additional evaluation
points for the confidence intervals in the range of the seen data
now by default has datax = TRUE
fixed issue with labeling
issues with datax fixed
gains argument jit.tol to allow jittering to take place also for
continuous observations, if observations are "too" close to each other
returnlevelplot
similar as qqplot as to additional methods
returnlevelplot now gains an argument threshold for POT
set datax argument in case it is missing in returnlevelplot ...
issues with datax fixed
gains argument jit.tol to allow jittering to take place also for
continuous observations, if observations are "too" close to each other
new internal method .checkEstClassForParamFamily-method to be called
immediately before returning an Estimate object (in functions Estimator(),
MCEstimator(), MDEstimator(), MLEstimator()); this allows to return an
object of S4 class specific to the resp. parametric family (by means of
S4 method dispatch); this is used in pkg 'RobExtremes' to produce, e.g.,
objects of class "GEVMCEstimate", i.e. which inherit from both
"MCEstimate" and "GEVEstimate", so that a diag-method for
"GEVEstimate" becomes available for this class.
enhanced imports in DESCRIPTION by explicating second order imports
helper function .isReplicated gains an optional argument tol
BUGFIXES:
fixed issue with slot withPosRestr in ParamFamParameter.R
fixed issue with check.validity (reported by B.Spangl)
fixed some minor issue in existsPIC (in case we get 0 matrix, and less strict tolerance)
fixed issue with returnlevelplot discovered by B. Spangl -- points had not been ordered
fixed CIs for qqplot and returnlevelplot
##############
v 2.5
##############
user-visible CHANGES:
GENERAL ENHANCEMENTS:
cleaned DESCRIPTION and NAMESPACE file as to Imports/Depends
under the hood:
For speeding up things, we now have an option withL2derivDistr = TRUE which
if FALSE skips computing the image distribution in two dimensional models,
i.e., have switched slot L2derivDistr from "DistrList" to "OptionalDistrList".
delayed calculation of variances and allow to skip or delay calculation of
L2derivDistr; to this end introduced new class unions
"OptionalNumericOrMatrixOrCall", "OptionalDistrListOrCall";
respectively at certain stages, evaluation of the call must then be forced
consequence: L2LocationScaleFamilies now use median mad as starting estimator
in robest roptest (and no longer call CvM-MDE)
small change to avoid frequent calls to getImageDistr
(L2)ParamFamily gains slots
.withEvalAsVar to allow delayed evaluation of variances
.withEvalL2derivDistr to allow delayed evaluation of L2derivDistr
.withMDE to control extra calls to MDEstimator that might not be necessary
in robest (e.g. with GParetoFamily())
correspondingly accessor L2derivDistr now checks whether it is a
call and if so evaluates
forgot to commit some changes in show() for asvar in the last round
in checkL2deriv, in addition, relative tolerances are also issued
for Fisher Information
fixed an issue with modifyModel in case of location scale models: in these
cases we do neither want to produce a call nor an evaluated call to
imageDistr...
added .Rbuildignore
exported some routines which had been internal so far to
avoid calls by :::
BUGFIXES:
moved generics to "distribution" and "samplesize" to pkg distr to avoid
conflict with pkg distrSim
##############
v 2.4
##############
user-visible CHANGES:
moved GumbelLocationFamily to new package "RobExtremes"
new function addAlphTrsp2col to add alpha transparency to a
given color; qqplot gains argument alpha.trsp to control for alpha transparency
under the hood:
added modifyModel method for ParamFamily, some minor corrections due to more strict checking in R devel
created folder vignettes and moved content of inst/doc/ to it
removed lazyload tag in DESCRIPTION
updated affiliation info in newDistributions.Rnw
deleted inst/doc folder
.Rbuildignore file as a reaction to B. Ripley's mail on r-devel,
"CRAN package sizes", Feb-14-2011
added computation of relative error in checkL2deriv -
maybe there is a better idea avoiding division by zero,
added DESCRIPTION tag "ByteCompile" to all our packages
updating maintainer email address and URL.
added argument no.readonly = TRUE to assignments of form opar <- par()
new intermediate classes/ class unions for scale families and scale shape families;
consequent use of argument validity.check in MCE estimators.
removed relics of ancient L2Fam-slot withPos (was introduced in a try)
introduced slot scaleshapename for L2ScaleShapeUnion and methods scalename und scaleshapename (accessor/replacers)
after change of @<- semantics by J. Chambers moved from class(M) <- class(model) to slotwise copying
S4Method "mceCalc", signature(x = "numeric", PFam = "ParamFamily") gains additional
calls to makeOKPar() to warrant admissible parameter values
Estimator can now deal with asymptotic variances if given; to this end
gains optional argument ParamFamily
put some examples in \dontrun to reduce check time on CRAN
deleted file GumbelLocationFamily.Rd (no longer needed)
Default name of Estimator is now "Estimator"
deleted no longer needed chm folders
BUGFIXES:
bugfixes in NbinomMeanSizeFamily
and NbinomwithSizeFamily (detected by Matthias!)
digamma was used instead of trigamma
validparameter: fixed a bug with slot withPosRestr (which is not a member of
L2ParamFamily but of the respective parameter!)
##############
v 2.3
##############
user-visible CHANGES:
introduced NbinomFamily in response to Markus Kalisch's mail to RsR
restated L2-deriv and L2-deriv distribution s.t. it is computationally easier to treat
also now allow 2-parametric model Nbinom (see SimpleL2ParamFamilies.R...)
++ Vignette:
uploaded vignette for distrMod (still to be done: insert exact volume,number,pages)
Matthias' Kommentare (Kreis-Symbol, Rem) ge�ndert
merged in Matthias' changes
integrated JSS version of vignette
vignette distrMod fertiggemacht
vignette announced in startup msg
meta-information included to vignette
under the hood:
DESCRIPTION files and package-help files gain a tag
SVNRevision to be filled by get[All]RevNr.R from utils in distr
BUGFIXES:
re-uploaded svn-multi.sty and svnkw.sty after error report by Jan de Leeuw.
for restoring old par() values, not all attributes may be set; hence deleted them from
stored value in plot functions by something like
opar$cin <- opar$cra <- opar$csi <- opar$cxy <- opar$din <- NULL
unnecessary Rplots.pdf deleted from inst folders of distr and
distrMod (are created anyway during vignette build)
##############
v 2.2.2
##############
Vignette to distrMod aka
M. Kohl and P. Ruckdeschel (2010): R Package distrMod: S4 Classes and Methods for Probability Models.
Journal of Statistical Software, 35(10), 1-27. \url{http://www.jstatsoft.org/v35/i10/}
there is accessor function completecases[.estimate]
slot samplesize only counts complete cases
accessor functions samplesize[.estimate] gains argument onlycompletecases;
if TRUE returns slot samplesize[.estimate] as is, otherwise adds
sum(completecases.estimate) to it
internally all Estimator functions work with data na.omit(x) instead of x
Models:
checkL2deriv gains ... argument to pass on accuracy arguments to E()
plotting:
new diagnostic function qqplot to check the quality of a model fit
special methods for first argument "ANY" (the data) and for second argument
of class "UnivariateDistribution", "ProbFamily",
comes with corresponding (pointwise/simultaneous) confidence intervals
flexible labelling of data points
GENERAL ENHANCEMENTS:
added tests/Examples folder with file distrMod-Ex.Rout.save to have
some automatic testing
added field "Encoding: latin1" to all DESCRIPTION files in order to avoid problems
with e.g. Windows locale when svn replaces $LastChangedDate
added TOBEDONE (sic!) files for each package (by accident also in trunc; these are empty so far)
INTERNALLY:
moved Distribution symmetry classes and corresponding methods/functions from distrMod to distr
in distrMod remove slots from class ProbFamily and L2ParamFamily
-distrSymm (information is already in slot distr)
-L2derivSymm (information will be in Random Variable L2deriv)
-L2derivDistrSymm (information will be in DistrList L2derivDistr)
changed behaviour of mceCalc() and consequently of MCEstimator(), MDEstimator(), MLEstimator():
Instead of mapping unallowed parameter values into allowed ones by makeOKPar(), thereby pretending
to optim/optimize that the unallowed parameters give reasonable criterion values, now always
a penalty is returned whenever the parameter is not valid. For profiling though, we still
keep the old behavior, i.e. map to allowed parameters by makeOKPar() in the returned criterion
function.
in mceCalc naming is "more" unique (to avoid unintended name clashes)
class MCEstimate gains slot optimwarn to gather warnings issued in optimization;
may be accessed with method optimwarn()
potentially, mleCalc now transports the value of the current parameter value
theta as argument thetaPar to the optimization criterion;
controlled for by argument withthetaPar (defaulting to FALSE)
Hence, if desired, particular criterion functions could make use of
this information, by, say computing the criterion differently for
different parameter values
We used it to check whether the numerically found optimum obeys
first order conditions (i.e. sum (L2deriv(x_i))=0)
new utility: .deleteDim to delete /only/ dim attribute
to deal with nuisance parameters:
utility .validTrafo(), in presence of nuisance, covering coordinates p+1..k,
now accepts for matrices either dim p x p or p x k
and in case ncol(trafo==k)
correspondingly modified validity function slot in ParamFamParameter()
method trafo is changed for nuisance parameters:
for signature ParamFamily, ParamFamParameter now takes special care
about presence of a nuisance parameter:
if so it returns as mat item a matrix with corresponding zero-columns for
the nuisance coordinates so that it has dim p x k where k=length(main)+length(nuisance)
.validTrafo calls in ParamFamParameter.R
(in generating function ParamFamParameter,
in trafo-methods signature ParamFamParameter, missing
in main<- method for signature ParamFamParameter
in trafo<- method for signature ParamFamParameter)
are now prepended with necessary dimension
calculations in order to check whether its dim is pxp or pxk (see point ".validTrafo")
show methods for class Estimate are a bit more careful:
in principle they accept estimate slots with a dim attribute
special care is taken to whether untransformed.asvar is not NULL / NA-free
removed unnecessary "fixed" component of parameter in ExpScaleFamily
BUGFIXES:
inserted Symmetry information in demo modelExp3.R
simplified treatment of random variable L2deriv in L2ParamFamily.R
small modifications to make modifyModel work with matrices in calls
small correction needed for case trafo in R^(1 x k)
plot should now work for models with trafo - shows untransformed family
mceCalc was building a named call with arguments x and Distribution and hence
MDEstimator did no longer work...
for MDEstimator, similarly, this is controlled by paramDepDist
there were problems in confint() when diag() was called with numeric of length one.
modified wrong use of "criterium" to "criterion"
a tiny buglet in prototype for trafo slot
yet another issue with "pretty printing", -> give default names "" if empty
the "dim"-issue:
estimate, untransformed.estimate, main, and nuisance from time to time
did not return numerics (instead: items with dim attribute...)
accessors to [untransoformed.]asvar now coerce to matrix, but only so if the item is not NULL
in .process.meCalcRes delete dim attribute for slots [untransformed.]estimate unless
already present in main (and nuisance)
yet another issue with accessor function to [untransformed.]estimate --- it ate the names....
setAs(,) was wrong for nuisance parameters
##############
v 2.1
##############
Rd-style:
several buglets detected with the fuzzier checking mechanism
cf [Rd] More intensive checking of R help files, Prof Brian Ripley, 09.01.2009 10:25)
[Rd] Warning: missing text for item ... in \describe? , Prof Brian Ripley,
MODELS
added mad.const to guarantee for mad-consistency in location scale model
loc/scale model: standardization by n not by (n-1) as in case of sd .
minor modification, L2derivDistr in case of location and scale families
some modifications such that LnormScaleFamily works properly ...
bug in LnormScaleFamily corrected ...
modifyModel gains argument .withL2derivDistr ---
if false needs not be calculated (as e.g. this is done in a particular
method calling the general method first...)
TRAFO
fixed some inconsistencies with slot trafo:
now when trafo is a function, we try to keep it as a function under
moves of the parametric model...
we introduce
a function trafo.fct() (see ?trafo.fct)
to access the "function" aspect of trafo
a function trafoEst() which transforms an existing estimator of class "estimate"
consistently (i.e. with corresponding untransfromed.estimate and untransformed.asvar
information and transformed asvar) by a "trafo" function; see ?trafoEst
ESTIMATION
minor correction sqrt((n-1)/n)*sd(x)
enhanced Covariance calculation for CvMDist-MDE
modified output in show - Confint-class
PLOTTING
fixed issue with cex.inner
fixed bug in plot-methods for argument "inner" under use of to.draw.arg argument
realized suggestions by A. Unwin, Augsburg;
plot for L2paramFamilies may be restricted to selected subplots;
L2ParamFamily plot in distrMod is now are as flexible as plot-methods in pkg distr
small changes in AllPlot.R in distrMod
plot-L2ParamFamily now also digests ... , in particular grid()
some fix in order to cover the case of argument panel.first=grid()
in the ... argument (needs a delayed evaluation...)
BUGFIXES
some minor issues in L2GroupFamilies (if locscalename is missing)
fixed issue with MCE, MLE and MDE; these are also defined for ParamFamily class
objects; so they need not have an Information slot
fixed a bug in L2GroupFamilies:
it must be .getLogDeriv(centraldistribution) instead of .getLogDeriv(distribution)
enhanced plotting (correct dispatch; opening of new device is controlled
by option("newDevice") )
after JMC's changes: gone through setIs relations to ensure
"correct" inheritance
moved license to LGPL-3
new plot()-methods capabilities comparable to those of plot()-methods
in package distr():
plot-L2ParamFamily now also digests ... , in particular panel.first=grid()
corrected some buglets:
corrected small bug in SimpleL2ParamFamilies.R ...
corrected small bug in GumbelLocationFamily ...
small modifications to modifyModel.R
... modification of model a crucial step ... find a better way to do this???
new show() for 'confint'
new 'confint' methods for robust confidence intervals
##############
v 2.0
##############
start of the package
includes Parametric Models (with corresponding S4 classes)
parameter (realized as corresponding S4 class) is split up into
+main part
+nuisance part
+fixed part
may be transformed by user defined trafo function
includes Minimum Criterium Estimators (with corresponding S4 classes)
---with particular cases
+Maximum Likelihood
+Minimum Distance Estimators for
Kolmogorov, Hellinger, Totalvariation, and Cramer von Mises distance
Minimum Criterum Estimators can (but do not need to) use method dispatch;
this way particular methods beyond numerical optimization can be used
without changing distrMod code
has Symmetry classes (useful for avoiding unnecessary integrations)
has biastype classes
has norm classes (to be used for differently standardized risks and ICs)
includes confint() methods for our Estimator classes
features risk classes (mainly used in RobASt packages, though)