我在使用gephi。 这是用于创建图形的软件,以平面svg格式导出图形。 如何将svg转换为d3.js代码
必须将图形放置在网页上,并使用交互式行为突出显示选择。 这是因为有1800个节点。
我想知道是否有方法通过将此SVG导入D3.js或其他工具将SVG代码转换为D3.js代码
以下是一些SVG格式的示例节点和链接。
xmlns 3360 xlink=' http://www.w3.org/1999/xlink ' zoomandpan=' magnify '
contentStyleType='text/css '
view box='-1491.000000-1489.000002998.8261722983.00000 ' height=' 2983.0 '
preserve aspect ratio=' xmidymidmeet ' xmlns=' http://www.w3.org/2000/SVG '
版本=' 1.1 '
d=' m-741.524292,330.655731 c-696.531250,212.884094-452.384125,103.716217-334.612488,148.709290 '
class=' vansdlpkshhbak ' stroke-opacity=' 0.6 '
stroke='#73c000'/
d=' m-334.612488,148.709290 c-379.605560,266.480927-623.752686,375.648804-741.524292,330.655731 '
class=' kshhbakvansdlp ' stroke-opacity=' 0.6 '
stroke='#73c000'/
d=' m-334.612488,148.709290 c-334.612488,148.709290-174.612488,148.709290 '
class=' kshhbak ' stroke-opacity=' 0.6 ' stroke=' # 73c 000 ' /
d=' m-1003.035095,296.450439 c-943.891846,250.989349-786.985413,271.512512-741.524292,330.655731 '
class=' linaroblujhvansdlp ' stroke-opacity=' 0.6 '
stroke='#73c000'/
class=' vansdlp ' cy=' 330.65573 ' stroke=' # 000000 '
stroke-opacity=' 1.0 ' stroke-width=' 1.0 ' /
class=' kshhbak ' cy=' 148.70929 ' stroke=' # 000000 '
stroke-opacity=' 1.0 ' stroke-width=' 1.0 ' /
class=' linaroblujh ' cy=' 296.45044 ' stroke=' # 000000 '
stroke-opacity=' 1.0 ' stroke-width=' 1.0 ' /
fill=' # 000000 ' stroke-line join=' round '
style='text-anchor: middle; dominant-baseline: central;'
font-family=' arial ' class=' vansdlp ' stroke=' # ffffff '
stroke-opacity=' 0.6 ' stroke-width=' 3.75 px '
vansdlp
fill=' # 000000 ' stroke-line join=' round '
style='text-anchor: middle; dominant-baseline: central;'
font-family=' arial ' class=' kshhbak ' stroke=' # ffffff '
stroke-opacity=' 0.6 ' stroke-width=' 15.0 px '
kshhbak