# Internal emplik functions

### Description

Internal emplik functions

### Usage

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 | ```
logelr(x,mu,lam)
logwelr(x,mu,wt,lam)
gradf(z,wt,lam)
llog(z, eps)
llogp(z, eps)
llogpp(z, eps)
Wdataclean2(z,d,wt=rep(1,length(z)))
Wdataclean3(z,d,zc=rep(1, length(z)),wt=rep(1,length(z)))
Wdataclean5(z,d,zc=rep(1, length(z)),wt=rep(1,length(z)),xmat)
DnR(x,d,w,y=rep(-Inf,length(x)))
solve3.QP(D, d, A, b, meq, factorized=FALSE)
WKM(x,d,zc=rep(1,length(d)),w=rep(1,length(d)))
WCY(x,d,zc=rep(1,length(d)),wt=rep(1,length(d)),maxit=25,error=1e-09)
LTRC(x,d,w=rep(1, length(d)),y=rep(-Inf, length(x)))
el.test.wt3(x,wt,mu,maxit,gradtol,Hessian,svdtol,itertrace)
iter(x, y, delta, beta)
MMRtime(x, d, age)
redistF(y, d, Fdist)
gradf2(lam, funt1, evt1, rsk1, funt2, evt2, rsk2, K, n)
gradf3(lam, funt1, evt1, rsk1, funt2, evt2, rsk2, K, n)
cumsumsurv(x)
emplikHs.test22(x1, d1, y1 = -Inf, x2, d2, y2 = -Inf,
theta, fun1, fun2, maxit = 25,
tola = 1e-07, itertrace = FALSE, ...)
``` |

### Details

These are not intended to be called by the user.

`Wdataclean2`

and
`DnR`

are used by the functions `emplikH1.test`

,
`emplikH2.test`

and `emplikdisc.test`

. It is also used by
`LTRC`

.

`DnR`

take the survival data as input, compute the number at risk
and number of observed events, and output only those time points where
there is some events. Notice the input must be ordered! We should use
Wdataclean2/3/5( ) first and then use the output there as the input of DnR.

`Wdataclean2`

will sort the data and collapse those that are true ties,
and the number of tied value is in the weights.

`logelr`

, `llog`

, `llogp`

and `llogpp`

are used by function `el.test`

. They are from Owen.

`Wdataclean2`

, `WKM`

and `solve3.QP`

are
used by function `el.cen.test`

.
WKM() is the weighted Kaplan-Meier.

`WCY`

is the weighted Chang and Yang self-consistent estimator
for doubly censored data.

`Wdataclean2`

is used by `el.cen.EM`

.

`LTRC`

is for Left Truncated and Right Censored data.

`gradf3`

is used by the function emplikHs.test2. (and stored there)

`el.test.wt3`

are similar to `el.test.wt`

and `el.test.wt2`

,
but can take vector mean as constraint. `llog`

, `llogp`

and
`llogpp`

are used by both `el.test.wt3`

and
`el.test.wt2`

. In addition `logwelr`

is used by `el.test.wt3`

.

`MMRtime`

estimate the Mean and Median residual life time at age
with right censored data.

`iter`

is for perform one iteration of EM in the Buckley-James
censored regression estimation.
`redistF`

is for redistribution of probability, according to Fdist.
Used in BJtest() and BJtestII().

`cumsumsurv`

is similar to rev(cumsum(rev( ))) but faster.
`emplikHs.test22`

similar to emplikHs.test2; and is used by RankRegTestH() only.

Want to suggest features or report bugs for rdrr.io? Use the GitHub issue tracker. Vote for new features on Trello.