Computes the current residuals from data and f_init and adds K new factors based on init_fn applied to these residuals. (If f_init is NULL then the residuals are the data).

flash_add_factors_from_data(data, K, f_init = NULL, init_fn = "udv_si")

Arguments

data

A flash data object.

K

Number of factors to add.

f_init

An existing flash fit object to add to.

init_fn

The function to use to initialize new factors (typically some kind of svd-like function).