Usage
GenerateNet ( N=1000 , m = 1 , mode = c(1,2,3) , alpha = 1, beta = 1 , sat_at = 100 , offset = 1 , rate = 0 , shape = 0 , mode_f = c("gamma") , num_seed = 2 , prob_m = FALSE , meanlog = 0 , sdlog = 1 , scale_pareto = 0.6, shape_pareto = 2.5, increase = FALSE , multiple_node = 1, specific_start = NULL, log = FALSE , custom_PA = NULL)
Arguments
N
Integer. Total number of nodes in the network (including the nodes in the seed graph). Default value is $1000$.
m
Integer. The number of edges of the new node. Default value is $1$.
mode
Integer. Indicates the attachment function to be used in generating the network. If mode == 1, the attachment function is $A_k = k^\alpha$. If mode == 2, the attachment function is $A_k = min(k,sat_at)^\alpha$. If mode == 3, the attachment function is $A_k = \alpha log (k)^\beta$. Default value is $1$.
alpha
Numeric. If mode == 1, this is the attachment exponent in the attachment function $A_k = k^\alpha$. If mode == 2, this is the attachment exponenet in the attachment function $A_k = min(k,sat_at)^\alpha$. If mode == 3, this is the alpha in the attachment function $A_k = \alpha log (k)^\beta$ + 1.
beta
Numeric. This is the beta in the attachment function $A_k = \alpha log (k)^\beta$ + 1.
sat_at
Integer. This is the saturation position sat_at in the attachment function $A_k = min(k,sat_at)^\alpha$.
offset
Numeric. The attachment value of degree $0$. Default value is $1$.
rate
Numeric. The rate parameter in the Gamma prior for node fitness. If either rate or shape is $0$, node fitness $f$ is fixed at $1$ (i.e. Barabasi-Albert model)
shape
Numeric. The shape parameter in the Gamma prior for node fitness. If either rate or shape is 0, node fitness $f$ is fixed at $1$ (i.e. Barabasi-Albert model)
mode_f
String. Indicates the true distribution for node fitness. "gamma" = gamma distribution, "log_normal" = log-normal distribution. "power_law" = power-law (pareto) distribution. Default value is "gamma".
meanlog
Numeric. Mean of the log-normal distribution in log scale. Default value is $0$.
sdlog
Numeric. Standard deviation of the log-normal distribution in log scale. Default value is $1$.
scale_pareto
Numeric. The scale parameter of the Pareto distribution. Default value is $0.6$.
shape_pareto
Numeric. The shape parameter of the Pareto distribution. Default value is $2.5$.
num_seed
Integer. The number of nodes of the seed graph (the initial state of the network). Default value is $2$.
prob_m
Logical. Indicates whether we fix the number of edges of a new node as a constant, or let it follows a Poisson
distribution. If prob_m == TRUE, the number of edges of a new node follows a Poisson distribution. The mean of this distribution depends on the value of increase and log. Default value is FALSE.
increase
Logical. Indicates whether we increase the mean of the Poisson distribution over time. If increase == FALSE, the mean is fixed at m. If increase == TRUE, the way the mean increases depends on the value of $log$. Default value is FALSE.
multiple_node
Numeric. The number of new nodes at each time-step. Default value is $1$.
specific_start
Numeric. If $specific_start$ is specified, then all the time-steps from time-step $1$ to $specific_start$ are grouped to become the initial time-step in the final output. This option is used when we want to create a network with a large initial network. Default value is $NULL$.
log
Logical. Indicates how to increase the mean of the Poisson distribution. If log == TRUE, the mean increases logarithmically with the number of current nodes. If log == FALSE, the mean increases linearly with the number of current nodes. Default value is FALSE.
custom_PA
Numeric vector. This is the user-input PA function. If $custom_PA$ is specified, then $mode$ is ignored, and the PA function $custom_PA$ is used to grow the network. Default value is $NULL$.