cancel
Showing results for 
Search instead for 
Did you mean: 

Head's Up! These forums are read-only. All users and content have migrated. Please join us at community.neo4j.com.

Filter specific data with Graph Algorithm

Hi all,

i have a dataset that holds data for 6 years. However, i want to apply a graph algorithm (community detection algorithm) in specific time periods. For example i want to apply it only on data that involves year 2013 only.

The Cypher query is as follows:
:param limit => ( 42);
:param config => ({
nodeProjection: '*',
relationshipProjection: {
relType: {
type: 'ANNUAL_CONTAINES_DATAPOINT',
orientation: 'UNDIRECTED',
properties: {}
}
}
});
:param communityNodeLimit => ( 10);

I want to keep all nodes in the algorithm, all nodes has an attribute that indicates the year. Any ideas how i can implement it in the query/??

Thanks in advance, Andreas

1 ACCEPTED SOLUTION

You'll want to load your nodes with the year property into your graph, then apply subgraph filtering to that graph: Graph Catalog - Neo4j Graph Data Science

Alternatively, you could use a cypher projection, although that will be a bit slower: Cypher projection - Neo4j Graph Data Science

View solution in original post

2 REPLIES 2

You'll want to load your nodes with the year property into your graph, then apply subgraph filtering to that graph: Graph Catalog - Neo4j Graph Data Science

Alternatively, you could use a cypher projection, although that will be a bit slower: Cypher projection - Neo4j Graph Data Science

Hi
The other tool is neo4j bloom(euler) and you can fine tune your query filters with it.
Thanking you
Sameer G