NetInd.to.sparseAdjMat {simcausal} | R Documentation |
Convert Network IDs Matrix into Sparse Adjacency Matrix
Description
Convert simcausal
network ID matrix (NetInd_k
) into a network represented by a sparse adjacency matrix.
Usage
NetInd.to.sparseAdjMat(NetInd_k, nF)
Arguments
NetInd_k |
Matrix of network IDs of dimension |
nF |
Integer vector of length |
Value
Network represented as a sparse adjacency matrix (S4 class object dgCMatrix
from package Matrix
).
NOTE: The friend IDs for observation i
will be listed in column i
(i.e, which(sparseAdjMat[,i])
are friends of i
).
See Also
network
; sparseAdjMat.to.igraph
; igraph.to.sparseAdjMat
; sparseAdjMat.to.NetInd
;
[Package simcausal version 0.5.6 Index]