Learn R Programming

multivarious (version 0.2.0)

bi_projector_union: A Union of Concatenated bi_projector Fits

Description

This function combines a set of bi_projector fits into a single bi_projector instance. The new instance's weights and associated scores are obtained by concatenating the weights and scores of the input fits.

Usage

bi_projector_union(fits, outer_block_indices = NULL)

Value

A new bi_projector instance with concatenated weights, scores, and other properties from the input bi_projector instances.

Arguments

fits

A list of bi_projector instances with the same row space. These instances will be combined to create a new bi_projector instance.

outer_block_indices

An optional list of indices for the outer blocks. If not provided, the function will compute the indices based on the dimensions of the input fits.

Examples

Run this code

X1 <- matrix(rnorm(5*5), 5, 5)
X2 <- matrix(rnorm(5*5), 5, 5)

bpu <- bi_projector_union(list(pca(X1), pca(X2)))

Run the code above in your browser using DataLab