I'm trying to visualize some 'graphs' (i.e. the mathematical objects with nodes and edges) using GraphPlot[]. I am defining the nodes using objects such as
node[1] = Column[{"NGC", "1"}, Center]
and then setting the option VertexLabeling->True. I am also using VerticCoordinateRules with terms like
node[1]->{Automatic, 2}
Overall, I'm happy with my results except for the fact that the nodes are rendered overlapping one another (see the image below). I have tried messing around with DataRange option, but that doesn't seem to have any effect. Does anyone have any suggestions on how to fix this problem?
Here is an example.
graphNodes["Lys"] = {
Column[{"AAA", "0.29"}, Center] -> Column[{"1CU", 11}, Center],
Column[{"AAA", "0.29"}, Center] -> Column[{"3UC", 14}, Center],
Column[{"AAA", "0.29"}, Center] -> Column[{"3UG", 9}, Center],
Column[{"AAA", "0.29"}, Center] -> Column[{"3UU", 7}, Center],
Column[{"AAA", "0.29"}, Center] -> Column[{"CUU", 14}, Center],
Column[{"AAA", "0.29"}, Center] -> Column[{"GUU", 10}, Center],
Column[{"AAA", "0.29"}, Center] -> Column[{"NGU", 4}, Center],
Column[{"AAA", "0.29"}, Center] -> Column[{"PAP", 2}, Center],
Column[{"AAG", "0 "}, Center] -> Column[{"3UU", 7}, Center],
Column[{"AAG", "0 "}, Center] -> Column[{"CAU", 5}, Center],
Column[{"AAG", "0 "}, Center] -> Column[{"CCU", 1}, Center],
Column[{"AAG", "0 "}, Center] -> Column[{"CUC", 2}, Center],
Column[{"AAG", "0 "}, Center] -> Column[{"CUU", 14}, Center],
Column[{"AAG", "0 "}, Center] -> Column[{"GUU", 10}, Center]};
nodeCoordinates["Lys"] = {Column[{"1CU", 11}, Center] -> {Automatic, 0},
Column[{"3UC", 14}, Center] -> {Automatic, 0},
Column[{"3UG", 9}, Center] -> {Automatic, 0},
Column[{"3UU", 7}, Center] -> {Automatic, 4},
Column[{"AAA", "0.29"}, Center] -> {Automatic, 2},
Column[{"AAG", "0 "}, Center] -> {Automatic, 2},
Column[{"CAU", 5}, Center] -> {Automatic, 0},
Column[{"CCU", 1}, Center] -> {Automatic, 0},
Column[{"CUC", 2}, Center] -> {Automatic, 0},
Column[{"CUU", 14}, Center] -> {Automatic, 4},
Column[{"GUU", 10}, Center] -> {Automatic, 0},
Column[{"NGU", 4}, Center] -> {Automatic, 0},
Column[{"PAP", 2}, Center] -> {Automatic, 0}};
GraphPlot[graphNodes[myAA], VertexLabeling -> True,
VertexCoordinateRules -> nodeCoordinates[myAA]]
And here's what I get,
ImageSize->...
and adjust as needed, or calculate specific coordinates and use them... $\endgroup$