rdpg_snapshot_bs {fase} | R Documentation |
Simulate binary edge networks with B-spline latent processes
Description
rdpg_snapshot_bs
simulates a realization of a functional network
with Bernoulli edges, according to an inner product latent process model.
The latent processes are generated from a -spline basis with equally
spaced knots.
Usage
rdpg_snapshot_bs(n,d,m,self_loops=TRUE,
spline_design,process_options)
Arguments
n |
A positive integer, the number of nodes. |
d |
A positive integer, the number of latent space dimensions. |
m |
A positive integer, the number of snapshots.
If this argument is not specified, it
is determined from the snapshot index vector |
self_loops |
A Boolean, if |
spline_design |
A list, describing the
|
process_options |
A list, containing additional optional arguments:
|
Details
The spline design of the functional network data (snapshot indices,
basis dimension) is generated using the information provided in
spline_design
, producing a -dimensional cubic
-spline basis with equally spaced knots.
The () latent process basis coordinates
for each node are generated as
iid Dirichlet
random variables with
-dimensional parameter
process_options$alpha_coord
or
rep(process_options$alpha_coord,d)
depending on the dimension
of process_options$alpha_coord
.
Roughly, smaller values of process_options$alpha_coord
will
tend to generate latent positions closer to the corners of the simplex.
is then rescaled so the overall network density is approximately
process_options$density
, and the Euclidean norm of
never exceeds
1
.
If the density requested is too high, it will revert to the maximum density
under this model ().
Then each latent process is given by
The symmetric adjacency matrix for
snapshot
has independent Bernoulli entries
with mean
for (or
with no self loops).
Value
A list is returned with the realizations of the basis coordinates, spline design, and the multiplex network snapshots:
A |
An array of dimension |
W |
An array of dimension |
spline_design |
A list, describing the
|
Examples
# Bernoulli edge data with B-spline latent processes, Dirichlet coordinates
# NOTE: for B-splines, x_max and x_min do not need to coincide with the
# max and min snapshot times.
data <- rdpg_snapshot_bs(n=100,d=10,
self_loops=FALSE,
spline_design=list(q=8,
x_vec=seq(-1,1,length.out=50),
x_min=-1.1,x_max=1.1),
process_options=list(alpha_coord=.2,
density=1/10))