Questions tagged [subgraph]

Use this tag for questions related to a Subgraph, a part of a larger graph.

313 questions
0
votes
1 answer

Find a connected subgraph with n nodes and e edges in python

I have a very large undirected graph dataset in the form of .txt, which I converted to networkx graph. I need to extract a connected subgraph containing N nodes (and E edges if possible, but not necessary). How do I go about it? This is the code I…
wamika
  • 21
  • 1
  • 8
0
votes
0 answers

Can a rails app and a subgraph created using The graph protocol share the same postgres db?

Do you know if it’s possible for a rails (or nodejs) app to share the same postgres db as a subgraph that's been created using The graph protocol? Or does the subgraph need a dedicated db? If it does, would a rails app reading from multiple database…
Sofiane
  • 111
  • 1
  • 6
0
votes
1 answer

Neo4j find n largest connected graphs with specific node types

Relatively new to Neo4j, but I am looking for some starting pointers or code examples for the following problem: I have a neo4j graph that contains 3 node types (Humans, Pets and Homes). I have 2 relationship types: FRIENDS and LIVING (see image…
Tobi
  • 85
  • 6
0
votes
1 answer

Has Apollo Federation support code-first approach?

I have code-first declarations on project. But I want to use them as microservices. In this case, how can i separate my typeDefs and resolvers according to Apollo's schema-first approach. Is it possible ?. I didn't find any resources that contain…
Batuhan
  • 1,521
  • 12
  • 29
0
votes
1 answer

Graphs and subgraphs layout

Using graphviz I want to generate the following graph (manually written in tikz for now): I currently succeeded in writing a dot file giving me the following result (there is a single node using html for the Pile table on the top, and one node also…
Manuel Selva
  • 18,554
  • 22
  • 89
  • 134
0
votes
1 answer

Graphviz nested subgraph orientation

I recently came across the image below. I know it was created with graphviz/dot, but the source code is not available (lost to time). Desired Output: I have been trying to find a way to reverse engineer the source code, but the horizontal ordering…
0
votes
1 answer

How to take a subgraph of a certain depth starting from a certain vertex in Neo4j

I need to take subgraph of given depth stating from some vertex using bfs. I've tried code similar to following MATCH (p:Node {id: '1'}) CALL apoc.path.subgraphAll(p, {minLevel: 0, maxLevel: 1}) YIELD nodes, relationships RETURN nodes,…
schernichkin
  • 1,013
  • 7
  • 15
0
votes
1 answer

Issue with union function of igraph

I tried using the union function on 2 graphs which where inducted subgraph of the same graph G (so there was no conflict among them). My problem is the original graph (and the subgraphs) are weighted, on the other hand the union of those subgraphs…
David
  • 13
  • 5
0
votes
1 answer

graphviz: is there a way to display only a subset of the subgraphs I have defined or have a B&W version(disable colors)?

are they easy ways to display only a subset of the subgraphs I have defined without commenting or else? to disable all colors/have a black and white version of the graph thanks P.S: it is for teaching/presentation purpose
stackoverflower
  • 301
  • 4
  • 14
0
votes
1 answer

Splitting a large network into many subgraphs using igraph

I have a large dataset comprising social network data from a number of different classrooms across different schools. I would like to split this large network into many smaller classroom networks according to a variable "class_id" or "school_id". I…
0
votes
1 answer

graphviz: is there a way to disable 1/ subgraph or 2/ labelling?

Is there a way to disable subgraph(same graph but without clustering) disable/hide labelling of vertex and hedge without redifining the whole graph? thanks P.S: it is for teaching/presentation purpose
stackoverflower
  • 301
  • 4
  • 14
0
votes
0 answers

How to create a special graph?

I wish to generate an undirected lattice graph G with following features: It has mxn vertexes; Each vertex has only two kinds of labels (0 or 1); Every txt subgraph is unique. For example, if the array of the vertex label of lattice graph G is 1 1…
Lilin2015
  • 1
  • 1
0
votes
1 answer

Graphviz: align subgraphs vertically

I’ve got four subgraphs that I’d like to (a) have the same width and (b) be aligned vertically (red > yellow > green > purple). I can’t figure out how to do that. Here is the dot code, simplified for clarity: digraph { rankdir = "TB"; …
thomas
  • 1
  • 2
0
votes
1 answer

How to draw sub-structures of a polycyclic aromatic which shows bond angles correctly?

thank you for reading my question. Assume that I have a polycyclic aromatic (let's call it "parent molecule") as shown below: smile = "c1ccc2ocnc2c1" mol = Chem.MolFromSmiles(smile) When I draw sub-structures of the parent molecule, I notice…
Mohammad
  • 775
  • 1
  • 14
  • 37
0
votes
0 answers

How to create a subgraph from a complex OWL graph which includes owl:intersectionOf, owl:equivalentClass, owl:restriction etc. using SPARQL CONSTRUCT

I want to create a subgraph consisting of only "Disorder sub-hierarchy" of SNOMED. I am trying to create this subgraph from the complete SNOMED-OWL graph using a SPARQL CONSTRUCT query. However the property consisting of owl:equivalentCLass/…