Description Usage Arguments Value Author(s) Examples
View source: R/plot.pa_result.R
This function plots the estimated attachment function from the corrected Newman's method or the Jeong's method. Its also plots additional information such as the estimated attachment exponenent (α when assuming A_k = k^α).
1 2 3 4 5 6 7 8 9 10 11 12 13 14 |
x |
An object of class |
net_stat |
An object of class |
plot_bin |
Logical. If |
high_deg |
Integer. Specifies the starting degree from which A_k is plotted. If this parameter is specified, the estimated attachment function is plotted from |
line |
Logical. Indicates whether to plot the line fitted from the log-linear model or not. Default value is |
col_point |
String. The name of the color of the points. Default value is "black". |
shade_point |
Numeric. Value between |
pch |
Numeric. The plot symbol. Default value is |
max_A |
Numeric. Specify the maximum of the horizontal axis. |
min_A |
Numeric. Specify the minimum of the horizontal axis. |
label_x |
String. The label of x-axis. If |
label_y |
String. The label of y-axis. If |
... |
Outputs the desired plot.
Thong Pham thongphamthe@gmail.com
1 2 3 4 5 6 7 8 9 10 | library("PAFit")
net <- generate_net(N = 1000 , m = 1 , mode = 1 , alpha = 1 , s = 0)
net_stats <- get_statistics(net)
result <- Newman(net, net_stats)
# true function
true_A <- result$center_k
# plot the estimated attachment function
plot(result , net_stats)
lines(result$center_k, true_A, col = "red") # true attachment function
legend("topleft" , legend = "True function" , col = "red" , lty = 1 , bty = "n")
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.