Neo4j,图数据科学 Python 库缩放函数

问题描述 投票:0回答:1

有谁知道这里提到的缩放函数https://neo4j.com/docs/graph-data-science/current/alpha-algorithms/scale-properties/是否存在于python库中,如果是的话我该如何调用他们?

neo4j neo4j-python-driver
1个回答
0
投票

所有功能均应通过 GDS python 客户端可用。 以下代码应该可以工作:

G, metadata = gds.graph.project(
  'myGraph',
  'Hotel',
  '*',
  { nodeProperties: ['avgReview', 'buildYear', 'storyCapacity'] }
)


gds.alpha.scaleProperties.stream(G, {
  'nodeProperties': ['buildYear', 'avgReview'],
  'scaler': 'MinMax'
})
© www.soinside.com 2019 - 2024. All rights reserved.