【问题标题】:igraph edge thickness and weightigraph 边缘厚度和重量
【发布时间】:2021-06-16 22:33:26
【问题描述】:

我有显示疫苗开发商、购买者和剂量/人均的数据(我根据体重进行了调整)。如何将疫苗开发商和购买者定义为节点,将剂量权重定义为边缘。另外,我如何根据重量操纵边缘的厚度。我是 Igraph 的新手,所以感谢您的帮助。

数据集:https://drive.google.com/file/d/1iJRLXBKTKhvVzX0lMsWngkHYQ263AxdY/view?usp=sharing

【问题讨论】:

    标签: r igraph


    【解决方案1】:

    您可以在plot 中使用edge.width,例如,

    g <- graph_from_data_frame(df)
    plot(g,edge.width = E(g)$Weight)
    

    【讨论】:

    • 谢谢,但我认为这是针对 python 的,我的项目需要使用 r studio。
    猜你喜欢
    • 1970-01-01
    • 2014-04-13
    • 1970-01-01
    • 2019-10-17
    • 2013-09-06
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 2019-03-12
    相关资源
    最近更新 更多