Tengo una tabla en SQL Server con el siguiente esquema:
- Partner_ID
- Child_ID
- Relationship_Name
Ejemplo de mis datos:
Partner_ID Child_ID Relationship_Name
A A1 Normal
B B1 Custom
B B2 Custom
A1 AAA Custom
B1 B1.1 Normal
B2 BBB Normal
Quiero dibujar una visualización de red (como los gráficos que podemos hacer usando Gephi) usando la tabla como entrada.
¿Existe alguna herramienta de código abierto que me permita hacer esta implementación?
¡¡¡Muchas gracias!!!
Podrías hacer esto en R:
# some newer libraries for dealing with networks
library(ggraph)
library(tidygraph)
theme_set(theme_void())
#read in data
txt <- read.table(text = "
Partner_ID Child_ID Relationship_Name
A A1 Normal
B B1 Custom
B B2 Custom
A1 AAA Custom
B1 B1.1 Normal
B2 BBB Normal",
header=TRUE, sep=" ", stringsAsFactors = FALSE)
# table (data frame) to graph object
gr <- as_tbl_graph(txt)
#plot it
ggraph(gr,layout="nicely")+
geom_edge_link(colour="blue",alpha=0.3)+
geom_node_point()+
geom_node_text(aes(label=name),size=4,repel=T)
Resultado:
Alejandro
Juan_Rodgers