Learn R Programming

MATES (version 0.1)

degree_distribution: Auxiliary function to compute rank matrix

Description

This function is used in 'P_Knear_rank' to compute the degrees

Usage

degree_distribution(G, sampleIDs)

Value

Numeric vector of degrees with the same length and order as sampleIDs

Arguments

G

Integer or numeric matrix with two columns, where each row represents a directed edge (from, to) in the k-NN graph

sampleIDs

Integer vector of node indices for which to compute degrees