question: private static void flipCoordinates ( final PhyloTreeView treeView , final SIDE rootSide ) { final PhyloTree tree = treeView . getPhyloTree ( ) ; for ( Node v = tree . getFirstNode ( ) ; v != null ; v = tree . getNextNode ( v ) ) { final Point2D loc = treeView . getLocation ( v ) ; switch ( rootSide ) { case TOP : treeView . setLocation ( v , loc . getY ( ) , loc . getX ( ) ) ; break ; case BOTTOM : treeView . setLocation ( v , loc . getY ( ) , - loc . getX ( ) ) ; break ; case RIGHT : treeView . setLocation ( v , - loc . getX ( ) , loc . getY ( ) ) ; break ; default : case LEFT : break ; } } }
target:  flip coordinates so as to fit the specified root side