# avr_proximity_multiple_target_sets: avr_proximity_multiple_target_sets In NetSci: Calculates Basic Network Measures Commonly Used in Network Medicine

## Description

Calculates the average proximity from a set of targets to a set of source nodes. It is calculate using a degree preserving randomization. It is calculated as described in Guney, E. et al (2016) <doi.org:10.1038/ncomms10331>

## Usage

 ``` 1 2 3 4 5 6 7 8 9 10``` ```avr_proximity_multiple_target_sets( set, G, ST, source, N = 1000, bins = 100, min_per_bin = 20, weighted = FALSE ) ```

## Arguments

 `set` Name of the sets you have targets for. (In a drug-target setup, those would be the drugs of interest). `G` The original graph (often an interactome). `ST` Set-Target data. It is a data.frame with two columns. ID and Target. `source` The source nodes (disease genes). `N` Number of randomizations. `bins` the number os bins for the degree preserving randomization. `min_per_bin` the minimum size of each bin. `weighted` consider a weighted graph? TRUE/FALSE

## Value

proximity and its significance based on the degree preserving randomization.

## Examples

 ``` 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27``` ```set.seed(666) net = data.frame( Node.1 = sample(LETTERS[1:15], 15, replace = TRUE), Node.2 = sample(LETTERS[1:10], 15, replace = TRUE)) net\$value = 1 net = CoDiNA::OrderNames(net) net = unique(net) net\$weight = runif(nrow(net)) g <- igraph::graph_from_data_frame(net, directed = FALSE ) S = c("N", "A", "F", "I") T1 = data.frame(ID = "T1", Target = c("H", "M")) T2 = data.frame(ID = "T2", Target = c("G", "O")) avr_proximity_multiple_target_sets(set = c('T1', 'T2'), G = g, source = S, ST = rbind(T1,T2), bins = 5, min_per_bin = 2) avr_proximity_multiple_target_sets(set = c('T1', 'T2'), G = g, source = S, ST = rbind(T1,T2), bins = 5, min_per_bin = 2, weighted = TRUE) ```

NetSci documentation built on Dec. 11, 2021, 9:21 a.m.