Skip to content

Commit 507d93d

Browse files
committed
Deploying to gh-pages from @ 0358150 🚀
1 parent 06f1087 commit 507d93d

File tree

4 files changed

+64
-23
lines changed

4 files changed

+64
-23
lines changed

pkgdown.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ pkgdown: 2.2.0
33
pkgdown_sha: ~
44
articles:
55
seine: seine.html
6-
last_built: 2026-02-10T04:27Z
6+
last_built: 2026-02-10T21:13Z
77
urls:
88
reference: https://corymccartan.com/seine/reference
99
article: https://corymccartan.com/seine/articles

reference/ei_test_car.html

Lines changed: 31 additions & 11 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

reference/ei_test_car.md

Lines changed: 31 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,14 @@ predictors; a missing `preproc` will lead to a warning.
1313
## Usage
1414

1515
``` r
16-
ei_test_car(spec, weights, iter = 1000, use_chisq = FALSE)
16+
ei_test_car(
17+
spec,
18+
weights,
19+
iter = 1000,
20+
undersmooth = 1.5,
21+
use_chisq = nrow(spec) >= 2000,
22+
use_hc = FALSE
23+
)
1724
```
1825

1926
## Arguments
@@ -40,7 +47,15 @@ ei_test_car(spec, weights, iter = 1000, use_chisq = FALSE)
4047
- iter:
4148

4249
The number of permutations to use when estimating the null
43-
distribution. Ignored when `use_chisq = TRUE`.
50+
distribution, including the original identity permutation. Ignored
51+
when `use_chisq = TRUE`.
52+
53+
- undersmooth:
54+
55+
A value to divide the estimated ridge penalty by when partialling out
56+
the partially linear component of the model. A larger value will
57+
smooth the partially linear component less, which may improve Type I
58+
error control in finite samples at the cost of power.
4459

4560
- use_chisq:
4661

@@ -49,6 +64,12 @@ ei_test_car(spec, weights, iter = 1000, use_chisq = FALSE)
4964
appropriate for larger sample sizes (Helwig 2022 recommends at least
5065
200 when a single predictor is used).
5166

67+
- use_hc:
68+
69+
If `TRUE`, use a heteroskedasticity-consistent covariance estimate.
70+
More computationally intensive, but may make a difference in small
71+
samples or when there is substantial heteroskedasticity.
72+
5273
## Value
5374

5475
A tibble with one row per outcome variable and columns describing the
@@ -62,9 +83,9 @@ The test is a Kennedy-Cade (1996) style permutation test on a Wald
6283
statistic for the coefficients not included in the "reduced" model that
6384
would be fit by
6485
[`ei_ridge()`](https://corymccartan.com/seine/reference/ei_ridge.md).
65-
The test is carried out by fitting a regression on a fully
66-
basis-expanded combination of covariates and predictors, and calculating
67-
a Wald statistic for the
86+
The test statistic is asymptotically chi-squared under the null and may
87+
be anti-conservative in small samples, especially when the
88+
dimensionality of the basis expansion is large.
6889

6990
## References
7091

@@ -100,12 +121,12 @@ spec = ei_spec(
100121
preproc = preproc
101122
)
102123

103-
ei_test_car(spec, iter=19) # use a larger number in practice
124+
ei_test_car(spec, iter=20) # use a larger number in practice
104125
#> # A tibble: 4 × 4
105126
#> outcome W df p.value
106127
#> <chr> <dbl> <int> <dbl>
107-
#> 1 pres_dem_hum 300. 105 0.05
108-
#> 2 pres_rep_nix 257. 105 0.05
109-
#> 3 pres_ind_wal 357. 105 0.05
110-
#> 4 pres_abs 206. 105 0.05
128+
#> 1 pres_dem_hum 296. 105 0.05
129+
#> 2 pres_rep_nix 254. 105 0.05
130+
#> 3 pres_ind_wal 353. 105 0.05
131+
#> 4 pres_abs 210. 105 0.05
111132
```

search.json

Lines changed: 1 addition & 1 deletion
Large diffs are not rendered by default.

0 commit comments

Comments
 (0)