Description Usage Arguments Value References Examples
Function to joint modelling of multiple network views using the Latent Space Jont Model (LSJM) Gollini and Murphy (2016). The LSJM merges the information given by the multiple network views by assuming that the probability of a node being connected with other nodes in each view is explained by a unique latent variable.
1 2 3 |
Y |
list containing a ( |
D |
integer dimension of the latent space |
sigma |
( |
xi |
vector of means of the prior distributions of α. Default |
psi2 |
vector of variances of the prior distributions of α. Default |
Niter |
maximum number of iterations. Default |
tol |
desired tolerance. Default |
preit |
Preliminary number of iterations default |
randomZ |
logical; If |
List containing:
EZ
(N
x D
) matrix containing the posterior means of the latent positions
VZ
(D
x D
) matrix containing the posterior variance of the latent positions
lsmEZ
list contatining a (N
x D
) matrix for each network view containing the posterior means of the latent positions under each model in the latent space.
lsmVZ
list contatining a (D
x D
) matrix for each network view containing the posterior variance of the latent positions under each model in the latent space.
xiT
vector of means of the posterior distributions of α
psi2T
vector of variances of the posterior distributions of α
Ell
expected log-likelihood
Gollini, I., and Murphy, T. B. (2016), 'Joint Modelling of Multiple Network Views', Journal of Computational and Graphical Statistics, 25(1), 246-265 http://arxiv.org/abs/1301.3759.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 | ## Simulate Undirected Network
N <- 20
Ndata <- 2
Y <- list()
Y[[1]] <- network(N, directed = FALSE)[,]
### create a new view that is similar to the original
for(nd in 2:Ndata){
Y[[nd]] <- Y[[nd - 1]] - sample(c(-1, 0, 1), N * N, replace = TRUE,
prob = c(.05, .85, .1))
Y[[nd]] <- 1 * (Y[[nd]] > 0 )
diag(Y[[nd]]) <- 0
}
par(mfrow = c(1, 2))
z <- plotY(Y[[1]], verbose = TRUE, main = 'Network 1')
plotY(Y[[2]], EZ = z, main = 'Network 2')
par(mfrow = c(1, 1))
modLSJM <- lsjm(Y, D = 2)
plot(modLSJM, Y, drawCB = TRUE)
plot(modLSJM, Y, drawCB = TRUE, plotZtilde = TRUE)
|
Loading required package: MASS
Loading required package: ergm
Loading required package: network
network: Classes for Relational Data
Version 1.14-377 created on 2019-03-04.
copyright (c) 2005, Carter T. Butts, University of California-Irvine
Mark S. Handcock, University of California -- Los Angeles
David R. Hunter, Penn State University
Martina Morris, University of Washington
Skye Bender-deMoll, University of Washington
For citation information, type citation("network").
Type help("network-package") to get started.
ergm: version 3.9.4, created on 2018-08-15
Copyright (c) 2018, Mark S. Handcock, University of California -- Los Angeles
David R. Hunter, Penn State University
Carter T. Butts, University of California -- Irvine
Steven M. Goodreau, University of Washington
Pavel N. Krivitsky, University of Wollongong
Martina Morris, University of Washington
with contributions from
Li Wang
Kirk Li, University of Washington
Skye Bender-deMoll, University of Washington
Based on "statnet" project software (statnet.org).
For license and citation information see statnet.org/attribution
or type citation("ergm").
NOTE: Versions before 3.6.1 had a bug in the implementation of the bd()
constriant which distorted the sampled distribution somewhat. In
addition, Sampson's Monks datasets had mislabeled vertices. See the
NEWS and the documentation for more details.
Loading required package: ellipse
Attaching package: 'ellipse'
The following object is masked from 'package:graphics':
pairs
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.