globalNullModel {netboxr} | R Documentation

## Generate global null model p-value

### Description

Randomly select the same number of nodes in the largest connected component of netbox result as a new gene candidate list and repeat multiple times to produce a distribution of node size and edge numbers. This distribution will be used to produce global p-value of netbox result based on the node size or edge numbers of largest component in the final network result.

### Usage

    globalNullModel(
      netboxGraph,
      networkGraph,
      directed,
      iterations = 30,
      numOfGenes = NULL,
      pValueAdj = "BH",
      pValueCutoff = 0.05
    )

### Arguments

`netboxGraph` | igraph network graph object. This igraph object contains NetBox algorithm identified network from `geneConnector` function
`networkGraph` | igraph network graph object. This igraph object contains curated network information
`directed` | boolean value indicating whether the input network is directed or undirected (default = FALSE)
`iterations` | numeric value for number of iterations
`numOfGenes` | numeric value for number of genes mapped in the initial network
`pValueAdj` | string for p-value correction method c("BH", "Bonferroni") as described in the details section (default = "BH")
`pValueCutoff` | numeric value of p-value cutoff for linker nodes (default = 0.05)

### Details

P-value correction methods include the Bonferroni correction ("bonferroni") or Benjamini & Hochberg ("BH").

### Value

a list of returned results

- globalNull: data frame of global randomization results

- globalNodesResult: data frame of global null tested results based on nodes

- globalEdgesResult: data frame of global null tested results based on edges

### Author(s)

Eric Minwei Liu, emliu.research@gmail.com

### Examples

    data(netbox2010)

    sifNetwork<-netbox2010$network
    graphReduced <- networkSimplify(sifNetwork,directed = FALSE)

    geneList<-as.character(netbox2010$geneList)

    results<-geneConnector(geneList=geneList,networkGraph=graphReduced,
                          pValueAdj='BH',pValueCutoff=0.05,
                          communityMethod='lec',keepIsolatedNodes=FALSE)

    names(results)

    # Suggested 100 iterations.
    # Use 5 interations in the exampel to save running time.
    # globalTest <- globalNullModel(netboxGraph=results$netboxGraph,
    #                              networkGraph=graphReduced,
    #                              iterations=5, numOfGenes = 274)

[Package netboxr version 1.7.1 Index]