public void createSVG(File f) {
try {
NanoGraphImage image = new NanoGraphImage(1000,1000);
image.setModel(g);
NodeRenderer nodeRenderer = new ImageNodeRenderer("/icons/mandarijn.png");
EdgeRenderer edgeRenderer = new ArrowEdgeRenderer();
edgeRenderer.setNormalColor("olivedrab");
image.getNanograph().setDefaultNodeRenderer(nodeRenderer);
image.getNanograph().setDefaultEdgeRenderer(edgeRenderer);
FileOutputStream fout = new FileOutputStream(f);
OutputStreamWriter writer = new OutputStreamWriter(fout);
image.storeAsSVG(writer);