【发布时间】:2009-05-20 02:35:04
【问题描述】:
我正在尝试使用GraphPlot 函数来构建Graph,其中每个节点都是一个图像。我想将图像显示为我的顶点。有人知道怎么做吗?
我尝试过这样的事情:
GraphPlot[ Map[If[# > 2.0 , 0, 1] &,
imgDistT, {2}],
VertexRenderingFunction -> (Inset[imgs[[#2]], #1, Center] &) ]
但这不起作用。 imgs 是我的每个顶点编号对应的图像列表。
作为健全性检查,如果我这样做:
GraphPlot[
Map[If[# > 2.0 , 0, 1] &, imgDistT, {2}],
VertexRenderingFunction -> (Inset[Text[#2], #1, Center] &) ]
然后就可以了,它会显示每个节点的顶点编号。
【问题讨论】: