simulate_quantile_curves {WRI} | R Documentation |
Simulate quantile curves
Description
This function simulates quantile curves used as a toy example
Usage
simulate_quantile_curves(x1, alpha, beta, t_vec)
Arguments
x1 |
n-by-1 predictor vector |
alpha |
parameter in location transformation |
beta |
parameter in variance transformation |
t_vec |
a length m vector - common grid for all quantile functions |
Value
quan_obs n-by-m matrix of quantile functions
References
Wasserstein F-tests and confidence bands for the Frechet regression of density response curves, Alexander Petersen, Xi Liu and Afshin A. Divani, 2019
Examples
alpha = 2
beta = 1
n = 100
x1 = runif(n)
t_vec = unique(c(seq(0, 0.05, 0.001), seq(0.05, 0.95, 0.05), seq(0.95, 1, 0.001)))
quan_obs = simulate_quantile_curves(x1, alpha, beta, t_vec)
[Package WRI version 0.2.0 Index]