library(graphframes)
library(sparklyr)
<- spark_connect(master = "local", version = "2.3.0")
sc <- sdf_copy_to(
v_tbl data.frame(id = 1:3, name = LETTERS[1:3])
sc,
) <- sdf_copy_to(
e_tbl data.frame(src = c(1, 2, 2), dst = c(2, 1, 3),
sc, action = c("love", "hate", "follow"))
) gf_graphframe(v_tbl, e_tbl)
gf_graphframe(edges = e_tbl)
Create a new GraphFrame
R/gf_interface.R
gf_graphframe
Description
Create a new GraphFrame
Usage
gf_graphframe(vertices = NULL, edges)
Arguments
Arguments | Description |
---|---|
vertices | A tbl_spark representing vertices. |
edges | A tbl_psark representing edges. |