F_cdf_rcpp2 {cmpp}R Documentation

Compute the CDF of the Parametric Proportional Odds Model (POM)

Description

This function computes the cumulative distribution function (CDF) of the parametric model (POM Approach).

Arguments

Params

A numeric vector of parameters.

Z

A numeric vector of covariates.

x

A numeric value representing the time point.

Value

A numeric value representing the CDF.

Examples

library(cmpp)
set.seed(1984)
features <- matrix(rnorm(300, 1, 2), nrow = 100, ncol = 3)
delta1 <- sample(c(0, 1), 100, replace = TRUE)
delta2 <- 1 - delta1
x <- rexp(100, rate = 1/2)
Initialize(features, x, delta1, delta2, h = 1e-5)
params <- rep(0.001, (ncol(features) + 2))
x <- 2
cdf_value <- F_cdf_rcpp2(params, features[1, ], x)
print(cdf_value)


[Package cmpp version 0.0.2 Index]