From baa0f4724e5cf6f91055307d7397e86ec4f3e418 Mon Sep 17 00:00:00 2001 From: ErikKusch Date: Tue, 6 Dec 2022 21:01:43 +0100 Subject: [PATCH] weighted data init --- R/DataInit.R | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/R/DataInit.R b/R/DataInit.R index 0d74026..9536de8 100644 --- a/R/DataInit.R +++ b/R/DataInit.R @@ -10,7 +10,12 @@ x } if(is(x) == "matrix"){ - x <- as.network(x, loops = TRUE) + x <- network::as.network(x, + matrix.type='adjacency', + # loops = TRUE, + directed = TRUE, + ignore.eval = FALSE, + names.eval = 'weight') } return(x) }