creating xml for graphs