I use the following code to colour the nodes that start with "n" as gray and the nodes starting with "m" letter with red colour
color_map = []
for node in c:
strnode = str(node)
if strnode.startswith("m"):
color_map.append('red')
else:
color_map.append('gray')
nx.draw(c, pos=nx.nx_agraph.graphviz_layout(c, prog='circo'),node_size=140, scale= 2, node_color=color_map,with_labels=True)
This works successfully as the picture shows below:
However, I have tried to draw the graph as a bipartite graph, meaning all the Red nodes to be aligned on the left side and all the gray nodes on the left side with no success. Any ideas?
*Fixed with @Mohammed Kashif answer, however the right side notes cannot displayed all:


