\HeaderA{mat2UndirG}{Change graph representations}{mat2UndirG}
\keyword{graphs}{mat2UndirG}
\begin{Description}\relax
A function to turn an adjacency matrix for a graph into a graphNEL object.
\end{Description}
\begin{Usage}
\begin{verbatim}
mat2UndirG(V, mat)
\end{verbatim}
\end{Usage}
\begin{Arguments}
\begin{ldescription}
\item[\code{V}] A vector of node names
\item[\code{mat}] A square symmetric matrix indicating the presence of edges
\end{ldescription}
\end{Arguments}
\begin{Details}\relax
\code{mat} is a square matrix with rows and columns corresponding to nodes in the graph.  Entries of "0" indicate the lack of an edge.  Since this is making an undirected graph, \code{mat} must be symmetric.
\end{Details}
\begin{Value}
A graphNEL object.
\end{Value}
\begin{Author}\relax
Denise Scholtens
\end{Author}
\begin{References}\relax
Balasubramanian, et al. (2004) A graph theoretic approach to integromics - integrating disparate sources of functional genomics data.
\end{References}
\begin{Examples}
\begin{ExampleCode}
library(graph)
a <- matrix(c(0,1,1,1,1,0,0,0,1,0,0,0,1,0,0,0),ncol=4)
ag <- mat2UndirG(V=letters[1:4],mat=a)
\end{ExampleCode}
\end{Examples}

