Skip to content

Commit bc2d7f8

Browse files
committed
Merge branch 'main' of github.com:BioRDM/Network-Analysis
2 parents ddb5757 + a2bfa23 commit bc2d7f8

File tree

2 files changed

+19
-11
lines changed

2 files changed

+19
-11
lines changed

R/Assemble_report.r

Lines changed: 8 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -52,7 +52,8 @@ assemble_report <- function(config) {
5252
report <- add_figure(
5353
report,
5454
plot = plot_graph(interactions, output_file = paste0(paths$figures, "/graph_", date_range, ".png")),
55-
fig_caption = "Visualisation of the Author network"
55+
fig_caption = "**Visualisation of the Co-Authorship Network Analysis**
56+
\nEach color represents a cluster of authors who are strongly connected within the network. The size of each node corresponds to the centrality of the author, with larger nodes indicating higher centrality and stronger connections within the network. The legend identifies the most central authors from each cluster, providing insight into key contributors within their respective groups."
5657
)
5758

5859
# Add network type paragraph
@@ -74,7 +75,10 @@ assemble_report <- function(config) {
7475
report <- add_figure(
7576
report,
7677
plot = plot_top_authors(interactions, n = 15, output_file = paste0(paths$figures, "/top_authors_", date_range, ".png")),
77-
fig_caption = "Direct connections between the 15 most central authors"
78+
fig_caption = "**Direct connections between the 15 most central authors**
79+
\nThis figure highlights the direct connections between the 15 most central authors in the network. Nodes positioned around the circle represent these top authors, and the thickness of the connecting lines indicates the strength of their collaboration (thicker lines represent stronger connections).
80+
\nA known limitation in social network analysis is reflected in cases where authors share the same last name and first initial, leading to duplicate entries being treated as a single node (in this figures, it looks like the authors connected to themselves). This issue arises when the dataset lacks full names, resulting in potential misrepresentation of distinct authors as one."
81+
7882
)
7983

8084
# Save centrality data as csv
@@ -87,7 +91,8 @@ assemble_report <- function(config) {
8791
report <- add_figure(
8892
report,
8993
plot = plot_cutpoints(interactions, output_file = paste0(paths$figures, "/cutpoints_", date_range, ".png")),
90-
fig_caption = "Visualisation of the Author network with cutpoints highlighted"
94+
fig_caption = "**Visualisation of the Author network with cutpoints highlighted**
95+
\nThis figure builds on Figure 1, with the addition of highlighting cutpoint authors in red. Cutpoints are authors whose removal would fragment the network, indicating their critical role in maintaining connectivity. The names of these cutpoint authors are listed above."
9196
)
9297

9398
# Save report as markdown

R/Report_text.r

Lines changed: 11 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -84,16 +84,16 @@ density_transitivity <- function(interactions) {
8484
"\nDensity measures the proportion of realised connections compared to all possible connections. It is calculated as:",
8585
"\n\n`Density = Number of Edges/(Number of Possible Edges) = Actual Edges/[nx(n-1)/2]`",
8686
"\n\n- **Value**: ", round(density * 100, digits = 2), "%",
87-
"\n- **Interpretation**: Values of Density range from 0 to 1.
88-
High Density: Close to 1, meaning most nodes are connected. This indicates a highly cohesive network.
89-
Low Density: Close to 0, meaning most nodes are not connected. Sparse networks are common in real-world systems.",
87+
"\n- **Interpretation**: The value of Density is in percantage.
88+
High Density: Close to 100%, meaning most nodes are connected. This indicates a highly cohesive network.
89+
Low Density: low percantage, meaning most nodes are not connected. Sparse networks are common in real-world systems.",
9090
"\n\n## Transitivity",
9191
"\nTransitivity, or the clustering coefficient, measures the tendency of nodes to form triangles (e.g., if A → B and B → C, then A → C). (In other words, if two nodes are connected to a common third node, they are also likely to be connected to each other). It is calculated as:",
9292
"\n\n`Transitivity = Number of Triangles/Number of Connected Triplets`",
9393
"\n\n- **Value**: ", round(transitivity * 100, digits = 0), "%",
94-
"\n- **Interpretation**: Values range from 0 to 1.
95-
High Transitivity: Close to 1, indicating a high level of clustering. Nodes tend to form tight-knit groups.
96-
Low Transitivity: Close to 0, indicating a lack of clustering.
94+
"\n- **Interpretation**: The value of Transitivity is in percantage.
95+
High Transitivity: Close to 100%, indicating a high level of clustering. Nodes tend to form tight-knit groups.
96+
Low Transitivity: low percantage, indicating a lack of clustering.
9797
A higher Transitivity value suggests that network tend to collaborate in groups, forming cohesive communities.")
9898
return(text)
9999
}
@@ -102,7 +102,7 @@ density_transitivity <- function(interactions) {
102102
centrality_metrics <- function(interactions) {
103103
centrality <- get_centrality(interactions)
104104
diameter <- get_diameter(interactions)
105-
text <- paste0("\n# Node Centrality and Centralization",
105+
text <- paste0("\n# Node Centrality and Centralisation",
106106
"\n## Degree Centrality",
107107
"\nDegree centrality measures the number of direct connections each node has in the network.
108108
Nodes with higher degree centrality are likely to be influential or well-connected individuals/entities.",
@@ -160,8 +160,11 @@ cutpoint_authors <- function(interactions) {
160160
cutpoint_names <- sort(cutpoint_names)
161161
text <- paste0("\n# Cutpoint Authors",
162162
"\n## Definition",
163-
"\nCutpoint authors are nodes in the network whose removal would increase the number of connected components in the network.",
163+
"\nCutpoint authors, also known as 'articulation points,' are critical nodes in the co-authorship network. If a cutpoint author is removed, the network would break into disconnected components, meaning the collaboration structure would become fragmented. These authors act as bridges, connecting different clusters or groups of researchers, and their presence is essential for maintaining the overall connectivity of the network.",
164+
"\n\n## Importance",
165+
"\nIdentifying cutpoint authors helps us understand who plays a pivotal role in sustaining collaboration across the network. Their removal could disrupt communication and collaboration between research groups, highlighting their strategic importance in the network's structure.",
164166
"\n\n## List of Cutpoint Authors",
167+
"\nThe following authors have been identified as cutpoints in this network:",
165168
"\n", paste(cutpoint_names, collapse = ", "))
166169
}
167170
return(text)

0 commit comments

Comments
 (0)