log_like_forces: create an initial configuration for the latent positions.

View source: R/log_like_forces.R

log_like_forcesR Documentation

create an initial configuration for the latent positions.

Description

This performs an iterative relaxation type algorithm to approximately find the positions of the nodes in the latent space that maximises the log-likelihood.

Usage

log_like_forces(net, D, X, B, m ,steps)

Arguments

net

network object on which to perform layout.

D

dimension of the latent space.

X

the initial guess for X

B

the intercept term.

m

usually N will suffice.

steps

maximum number of iteration steps.

Details

Usually only used internally in vblpcmstart()

Value

Matrix of latent positions X

Author(s)

Michael Salter-Townshend

See Also

igraph::layout.fruchterman.reingold

Examples

data(sampson)
N=network.size(samplike)
X=matrix(runif(N*2,-2,2),ncol=2)
XX=vblpcmcovs(N,"plain",as.sociomatrix(samplike))
out<-log_like_forces(samplike, 2, X, 0, m=N, 1e3)
plot(samplike,coord=out$X)

VBLPCM documentation built on March 31, 2023, 9:21 p.m.