cpm.predict.Rd
predicting scores using a previously trained CPM model
cpm.predict(model, test.data, network = "both")
A list object generated using cpm.train()
An N x E matrix containing the vectorized edges of subjects whose outcomes/scores are to be predicted. This matrix has to contain the same number of columns as the matrix of features used to train the CPM model
A string to specify which network strength('positive'
,'negative'
or 'both'
) to use in the outcome prediction. Set to 'both'
by default
Returns a vector of predicted outcomes if network='positive'
or network='negative'
.
In the case of network='both'
, a data.frame containing the predicted scores using the positive, negative, and the combined positive + negative models will be returned
This function takes a previously trained CPM model's weights to calculate the positive and negative network strengths for each subject. Then these network strengths are multiplied with the regression coefficients in the CPM model to compute a predicted score.
if (FALSE) {
model1=cpm.predict(model=model1, data=FC_data.test,network="both")
}