cbail / textnets

R package to perform automated text analysis using network techniques
MIT License
211 stars 62 forks source link

Error in graph_to_tree(graph, mode = direction) : Graph must be directed #28

Open cvolker opened 2 years ago

cvolker commented 2 years ago

When I tried to visualize the network, I keep getting this error: Error in graph_to_tree(graph, mode = direction) : Graph must be directed. Any suggestion on what might be the problem?

cbail commented 2 years ago

Hi- hard to help without knowing which functions you are using and what your data look like. If you post your code here either I or someone else may be able to help (but I am a bit short on time right now unfortunately, so apologies in advance if I can't get back to you right away)

LisaHuelsmann commented 2 years ago

I faced the same issue - I circumvented it by setting ggraph(pruned) to ggraph(pruned, 'tree') in the function VisTextNet() as the suggested here.

Probably, the ggraph package changed - so this may be something to change in case you consider maintaining the package.