Many researchers have specific expectations about the relations between parameters, such as means or regression coefficients. These expectations can often be expressed as order (inequality) restrictions, for example \(\mu_1 \leq \mu_2 \leq \mu_3\). Such hypotheses are called informative hypotheses.
restriktor makes it easy to test such theory-based hypotheses and to compare them, in (generalized) linear models and beyond. Incorporating your expectations directly in the analysis has clear benefits:
you test the hypothesis you are actually interested in;
substantially more power than classical tests;
no need for post-hoc tests and no inflated type I error rate.
restriktor offers two complementary approaches:
Hypothesis testing
Is the evidence strong enough to reject the null hypothesis in favour of my ordering? Order-constrained estimation and testing with restriktor() and iht(): F-bar, Wald, score and likelihood-ratio tests, robust and bootstrapped inference. Gives p-values. Hypothesis testing →
Model selection
Which of my hypotheses is best supported by the data, and how much better? Compare a set of theory-based hypotheses, or one hypothesis against its complement, with the GORIC(A) in goric(). Combine evidence over studies with evSyn(). Gives weights and ratios of support. Model selection →
A first example
The dataset ZelazoKolb1972 contains the age (in months) at which infants start to walk, for four treatment groups. The expectation is that walking exercises reduce the mean age at which a child starts to walk:
Order-constrained means in an ANOVA layout
library(restriktor)# constraints use the factor name followed by the level namesmyConstraints <-' GroupActive < GroupPassive < GroupControl < GroupNo '# fit the unrestricted model; -1 removes the intercept so that the# coefficients are the group meansfit.ANOVA <-lm(Age ~-1+ Group, data = ZelazoKolb1972)# hypothesis testing: test the informative hypothesisiht(fit.ANOVA, constraints = myConstraints)
Restriktor: restricted hypothesis tests:
Multiple R-squared remains 0.986
Constraint matrix:
GroupActive GroupControl GroupNo GroupPassive op rhs active
1: -1 0 0 1 >= 0 no
2: 0 1 0 -1 >= 0 no
3: 0 -1 1 0 >= 0 no
Overview of all available hypothesis tests:
Global test: H0: all parameters are restricted to be equal (==)
vs. HA: at least one inequality restriction is strictly true (>)
Test statistic: 6.4267, p-value: 0.03086
Type A test: H0: all restrictions are equalities (==)
vs. HA: at least one inequality restriction is strictly true (>)
Test statistic: 6.4267, p-value: 0.03086
Type B test: H0: all restrictions hold in the population
vs. HA: at least one restriction is violated
Test statistic: 0.0000, p-value: 1
Joint Type A and Type B test (Wolak, 1989, Theorem 1):
joint tail probability under H0: Rb = r (least favorable null)
Pr[Type B >= 0.0000, Type A >= 6.4267]: p-value: 0.03086
Type C test: H0: at least one restriction is false or active (==)
vs. HA: all restrictions are strictly true (>)
Test statistic: 0.3807, p-value: 0.3538
Note: Type C test is based on a t-distribution (one-sided),
all other tests are based on a mixture of F-distributions.
The Type B test is not rejected and the Type A test is rejected: the data support the ordering. With model selection, we compare the same hypothesis with its complement, that is, with all orderings that are not in line with it:
# model selection: the hypothesis versus its complementgoric(fit.ANOVA, hypotheses =list(H1 = myConstraints),comparison ="complement")
restriktor (0.7): generalized order-restricted information criterion:
Results:
Values:
model loglik penalty goric
1 H1 -40.014 3.098 86.224
2 complement -40.102 4.869 89.940
Weights:
model loglik.weights penalty.weights goric.weights
1 H1 0.522 0.855 0.865
2 complement 0.478 0.145 0.135
Conclusion:
The order-restricted hypothesis 'H1' has 6.41 times more support than its
complement.
---
Additional information:
- Note: The log-likelihood (loglik) value of the best hypothesis Hypothesis
'H1' is close to the log-likelihood (loglik) value of Hypothesis
'complement'. You may want to use the benchmark() function to investigate
whether this is the case. If so, then this indicates that there is
support for their boundary. More details can be found in the vignette
'Guidelines_GORIC_output' (to open it, run
vignette("Guidelines_GORIC_output", package = "restriktor")) and in the
decision tree on https://github.com/rebeccakuiper/Tutorials (the file
'Decision tree - Interpretation.pdf').
- The benchmark() function can be used to label the height of the output,
for example, the height of the ratio(s) of weights (e.g., to say whether
that value denotes medium, high, or very large evidence). More details
can be found in the vignette 'Guidelines_GORIC-benchmarks'; to open it,
run vignette("Guidelines_GORIC-benchmarks", package = "restriktor").
See example 1 for a step-by-step explanation of both approaches.
News
12-2026 restriktor 0.7 (development version) is available on GitHub, with iht_joint(), FIML for missing data, group_means(), goric_posthoc() and goric_CI(). What’s new?
11-06-2026 restriktor 0.6-50 released on CRAN. What’s new?