View source: R/old/network_dist_pairwise_genes.R
network_dist_pairwise_genes | R Documentation |
Compute the pairwise Hamming
or Jaccard
distance between binary edge weights of the
same genes in two different network topologies (denoted as adj_mat_qry
and adj_mat_sbj
).
network_dist_pairwise_genes(
adj_mat_qry,
adj_mat_sbj,
dist_type = "hamming",
print_message = TRUE
)
adj_mat_qry |
a binary adjacency matrix generated with |
adj_mat_sbj |
a binary adjacency matrix with the same genes as in |
dist_type |
a distance method that shall be applied on the binary values for each gene. Available options are:
|
print_message |
shall massages be printed? Default is |
Hajk-Georg Drost
## Import and rescale PIDC network
# path to PIDC output file
pidc_output <- system.file('beeline_examples/PIDC/outFile.txt', package = 'edgynode')
# import PIDC specific output
pidc_parsed <- pidc(pidc_output)
#Set diagonal values
diag(pidc_parsed) <- 1
# rescaling PIDC output
pidc_rescaled <- network_rescale(pidc_parsed)
pidc_binary_adj_mat <- network_make_binary(pidc_rescaled, threshold = "median")
# compute hamming distances for each gene between input matrices
network_dist_pairwise_genes(pidc_binary_adj_mat,
pidc_binary_adj_mat, dist_type = "hamming")
# compute jaccard distances for each gene between input matrices
network_dist_pairwise_genes(pidc_binary_adj_mat,
pidc_binary_adj_mat, dist_type = "jaccard")
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.