evaluate: Inference Evaluation

Description Usage Arguments Details Value See Also Examples

View source: R/evaluate.R

Description

evaluate compares the inferred network to the true underlying network for several threshold values and appends the resulting confusion matrices to the returned object.

Usage

1
    evaluate(inf.net,true.net,sym=TRUE,extend=0)

Arguments

inf.net

An adjacency matrix representing the inferred network.

true.net

An adjacency matrix representing the true underlying network.

sym

Logical, make a symmetric evaluation (default = TRUE).

extend

Integer, specifying the desired number of links to extend in the network (default=0)

Details

The first edgelist network inet is compared to the true underlying network, tnet, in order to compute the metrics of the performance. If extend is specified, extend links that network inet has set to 0 are added to the inferred network randomly at the end of the edgelist.

Value

evaluate returns a matrix with four columns representing TP,FP,TN,FN. These values are computed for each of the predicted links that should be sorted. Thus, each row of the returned object contains the confusion matrix as a function of the cutoff in the edgelist.

See Also

netbenchmark

Examples

1
2
3
4
5
    # Inference
    inf.net <- cor(syntren300.data)
    #Evaluate
    table <- evaluate(inf.net, syntren300.net)
    table.nosym <- evaluate(inf.net, syntren300.net,sym=FALSE)

netbenchmark documentation built on April 28, 2020, 7 p.m.