Learn R Programming

NetworkToolbox (version 1.1.1)

MaST: Maximum Spanning Tree

Description

Applies the Maximum Spanning Tree (MaST) filtering method

Usage

MaST(data, normal = FALSE, weighted = TRUE, depend = FALSE,
  na.data = c("pairwise", "listwise", "fiml", "none"))

Arguments

data

Can be a dataset or a correlation matrix

normal

Should data be transformed to a normal distribution? Defaults to FALSE. Data is not transformed to be normal. Set to TRUE if data should be transformed to be normal (computes correlations using the cor_auto function from the qgraph package)

weighted

Should network be weighted? Defaults to TRUE. Set to FALSE to produce an unweighted (binary) network

depend

Is network a dependency (or directed) network? Defaults to FALSE. Set TRUE to generate a MaST-filtered dependency network (output obtained from the depend function)

na.data

How should missing data be handled? For "listwise" deletion the na.omit function is applied. Set to "fiml" for Full Information Maxmimum Likelihood (psych package). Full Information Maxmimum Likelihood is recommended but time consuming

Value

A sparse association matrix

References

Adapted from: https://www.mathworks.com/matlabcentral/fileexchange/23276-maximum-weight-spanning-tree--undirected

Examples

Run this code
# NOT RUN {
weighted_MaSTnetwork<-MaST(neoOpen)


unweighted_MaSTnetwork<-MaST(neoOpen,weighted=FALSE)

# }

Run the code above in your browser using DataLab