Opening the graph window in root

You also have to install an X server (e.g. VcXsrv) and run Xlaunch before opening the Ubuntu window. See here for configuration: