This function calls the underlying C++ function `predict_tensor_cpp` to compute predicted responses given a flattened tensor, low-rank coefficient matrices, and scalar covariate coefficients.
predict_tensor_cpp(X_vec, beta, gam, n, p, d, rank)Numeric vector of length n
Flattened tensor (numeric vector of length n*p*d)
List of p×d matrices representing tensor coefficients
Numeric vector of scalar coefficients
Number of observations
Number of rows in each beta matrix
Number of columns in each beta matrix
Rank of tensor decomposition