我正在尝试使用javascript将neo4j的json结果显示为图形表示.Below是我的代码
<html>
<body>
<div class="alchemy" id="alchemy"></div>
<link rel="stylesheet" href="http://cdn.graphalchemist.com/alchemy.min.css" />
<script src="https://cdnjs.cloudflare.com/ajax/libs/alchemyjs/0.4.2/alchemy.min.js"></script>
<script type="text/javascript">
var config = {
dataSource: {
"comment": "Charlize Theron's 'ego' network as GraphJSON",
"nodes": [
{
"caption": "Screen Actors Guild Award for Outstanding Performance by a Female Actor in a Miniseries or Television Movie",
"type": "award",
"id": 595472
},
{
"caption": "Children of the Corn III: Urban Harvest",
"type": "movie",
"id": 626470
},
{
"caption": "Sleepwalking",
"type": "movie",
"id": 795744
},
],
"edges": [
{
"source": 314003,
"target": 621675,
"caption": "ACTED_IN"
},
{
"source": 314003,
"target": 818608,
"caption": "ACTED_IN"
},
{
"source": 314003,
"target": 601849,
"caption": "NOMINATED"
},
]
}
};
alchemy = new Alchemy(config)
</script>
我没有得到输出,错误是:d3未定义,d不是函数
如果有人可以提供帮助,请建议如何以图表格式显示结果