NetAnalyzer: Network analyzer

View source: R/NetAnalyzer.R

NetAnalyzerR Documentation

Network analyzer

Description

The NetAnalyzer function can calculate the degree, clustering coefficient, betweeness and closeness centrality for each node and the shortest path distance for each pair of nodes. The NetAnalyzer function can also plot the distributions for these measurements.

Usage

NetAnalyzer(inputNetwork, outputFileName,edgeType="unweighted")

Arguments

inputNetwork

The network under analysis. inputNetwork can be the directory of the input network file including the file name with "net" extension. If edgeType is "unweighted", each row represents an edge with two node names separated by a tab or space. If edgeType is "weighted", each row represents an edge with two node names and edge weight separated by a tab or space. inputNetwork can also be a data object in R (data object must be igraph, graphNEL, matrix or data.frame class).

edgeType

The type of the input network: "weighted" or "unweighted".

outputFileName

The name of the output file.

Value

The function will output two "txt" files and five "pdf" files. Two "txt" files contain degree, clustering coefficient, betweeness and closeness centrality for each node and the shortest path distance for each pair of nodes. Five "pdf" files are the distributions of these measurements.

Author(s)

Jing Wang

Examples

	inputNetworkDir <- system.file("extdata","exampleNetwork.net",package="NetSAM")
	outputFileName <- paste(getwd(),"/NetSAM",sep="")
	NetAnalyzer(inputNetworkDir,outputFileName,"unweighted")

bingzhang16/NetSAM documentation built on April 3, 2024, 3:35 a.m.