From b8ecce647ccb0e40954cb808c4e1040edae6e666 Mon Sep 17 00:00:00 2001 From: mef Date: Thu, 8 Jun 2023 16:04:37 +0000 Subject: [PATCH] (math/R-sandwich) Updated 3.0.1 to 3.0.2 # sandwich 3.0-2 * Added new argument `aggregate = TRUE` to `meatPL()` which is thus inherited by `vcovPL()`. By default, this still yields the Driscoll & Kraay (1998) covariance matrix. When setting `aggregate = FALSE` the cross-sectional and cross-serial correlation is set to zero, yielding the "pure" panel Newey-West covariance matrix. * Bug fix in `vcovCL(..., type = "HC2")` for `glm` objects or `lm` objects with weights. The code had erroneously assumed that the hat matrices were all symmetric (as in the `lm` case without weights). This is corrected now. (Detected and reported by Bixi Zhang.) * Issue a warning in `vcovHC()` for HC2/HC3/HC4/HC4m/HC5 if any of the hat values are numerically equal to 1. This leads to numerically unstable covariances, in the most extreme case `NaN` because the associated residuals are equal to 0 and divided by 0. (Suggested by Ding Peng and John Fox.) * Speed improvement in `vcovBS.lm()`: For `"xy"` bootstrap, `.lm.fit()` rather than `lm.fit()` is used which is somewhat more efficient in some situations (suggested by Grant McDermott). For `"residual"` and wild bootstrap, the bootstrap by default still samples coefficients via QR decomposition in each iteration (`qrjoint = FALSE`) but may alternatively sample the dependent variable and then apply the QR decomposition jointly only once (`qrjoint = TRUE`). If the sample size (and the number of coefficients) is large, then `qrjoint = TRUE` may be significantly faster while requiring much more memory (proposed by Alexander Fischer). * Enable passing score matrix (as computed by `estfun()`) directly to `bwAndrews()` and `bwNeweyWest()`. If this is used, the score matrix should either have a column `(Intercept)` or the `weights` argument should be set appropriately to identify the column pertaining to the intercept (if any). * The vignettes have been tweaked so that they still "run" without technical errors when suggested packages (listed in the VignetteDepends) are not available. This is achieved by defining replacement functions that do not fail but lead to partially non-sensical output. A warning is added in the vignettes if any of the replacements is used. --- math/R-sandwich/Makefile | 4 ++-- math/R-sandwich/distinfo | 8 ++++---- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/math/R-sandwich/Makefile b/math/R-sandwich/Makefile index 6c3ac1a7ee0c..c4aacfb4f0c5 100644 --- a/math/R-sandwich/Makefile +++ b/math/R-sandwich/Makefile @@ -1,7 +1,7 @@ -# $NetBSD: Makefile,v 1.3 2021/09/18 11:43:01 mef Exp $ +# $NetBSD: Makefile,v 1.4 2023/06/08 16:04:37 mef Exp $ R_PKGNAME= sandwich -R_PKGVER= 3.0-1 +R_PKGVER= 3.0-2 MAINTAINER= pkgsrc-users@NetBSD.org COMMENT= Robust covariance matrix estimators diff --git a/math/R-sandwich/distinfo b/math/R-sandwich/distinfo index e5f3d7ed7c85..45a4a6ed572b 100644 --- a/math/R-sandwich/distinfo +++ b/math/R-sandwich/distinfo @@ -1,5 +1,5 @@ -$NetBSD: distinfo,v 1.4 2021/10/26 10:55:32 nia Exp $ +$NetBSD: distinfo,v 1.5 2023/06/08 16:04:37 mef Exp $ -BLAKE2s (R/sandwich_3.0-1.tar.gz) = 7decddb372c549eca5794ac9e40414589aad4e3c63596c7601ce1a5ce96dda45 -SHA512 (R/sandwich_3.0-1.tar.gz) = fa2117c0d357aea85bab3468789739e218d87552535a8c5aaabb5c1191883304dfd8ac5109d7104ab15fd4535c5f1f4de88a5779ad1e573efc73b0ae567c6769 -Size (R/sandwich_3.0-1.tar.gz) = 1482805 bytes +BLAKE2s (R/sandwich_3.0-2.tar.gz) = 45c7528495740b82247587bcae6db68c0dccacc0ba9433445487698d3916ce4e +SHA512 (R/sandwich_3.0-2.tar.gz) = 6a976554df87a6776be9209c1680864be91c8b35a95482cc065151a05fe970c7833a87c896986674eb6c166ff14a85b90c4d54980e1e56aaecf62b37c3223d88 +Size (R/sandwich_3.0-2.tar.gz) = 1356080 bytes