# Small simulated example -----------------------------------------
set.seed(42)
N <- 6; I <- 10
alpha <- rnorm(N)
beta <- rnorm(I, sd = 0.7)
dist <- abs(matrix(rnorm(N * I, sd = 0.8), N, I)) # fake distances
# pip_profile() defaults to the fountain view
interprofile(alpha = alpha,
beta = beta,
distance_mat = dist,
focal_id = 2)
# Switch to waterfall with the same data
interprofile("waterfall",
alpha = alpha,
beta = beta,
distance_mat = dist,
item_group = rep(LETTERS[1:2], length.out = length(beta)),
y_limits=c(-3,2))
Run the code above in your browser using DataLab