invmod: Inverse Modulus

View source: R/mod_calc_RD.R

invmodR Documentation

Inverse Modulus

Description

Calculates the inverse modulus for the regression function at a point problem. More specifically, this calcultes ω^{-1}(b, Λ_{V+}(C),Λ_{V+}(C')) .

Usage

invmod(b, C_pair, X, mon_ind, sigma, swap = FALSE)

Arguments

b

point where the inverse modulus is evaluated at.

C_pair

a pair of smoothness parameters (C, C').

X

n by d design matrix.

mon_ind

index of the monotone variables.

sigma

standard deviation of the error term (either length 1 or n).

swap

indicator for whether we take (C', C) instead of (C, C').

Value

the value of inverse modulus given ω = b.

Examples

X <- matrix(c(1, -2, -3, 4, 5, -6), nrow = 3, ncol = 2)
mon_ind <- c(1, 2)
C_pair <- c(0.5, 1)
sigma <- c(1, 2, 1)
invmod(1, C_pair, X, mon_ind, sigma)
invmod(1, c(Inf, 1), X, mon_ind, sigma)

koohyun-kwon/rdadapt documentation built on May 8, 2022, 8:49 p.m.