predictCMF: Predict with CMF

Description Usage Arguments Details Value Author(s) Examples

View source: R/CMF.R

Description

Code for predicting missing elements with an existing CMF model. The predictions are made for all of the elements specified in the list of input matrices X. The function also returns the root mean square error (RMSE) between the predicted outputs and the values provided in X.

Usage

1
predictCMF(X, model)

Arguments

X

A list of sparse matrices specifying the indices for which to make the predictions. These matrices must correspond to the structure used for X when learning the model with CMF.

model

A list of model parameter values provided by CMF.

Details

Note that X needs to be provided as a set of triplets instead of as a regular matrix. See matrix_to_triplets.

Value

A list of

out

A list of matrices corresponding to predictions for each matrix in X.

error

A vector containing the root-mean-square error for each matrix separately.

Author(s)

Arto Klami and Lauri Väre

Examples

1
# See CMF-package for an example.

CMF documentation built on March 14, 2020, 1:07 a.m.