code: def result(filetype="PNG",saveas=None, host=cytoscape_host,port=cytoscape_port):
      
      sleep(1)
  
      def MAKETMP():
          (fd, tmp_file) = tempfile.mkstemp()
          tmp_file="/tmp/"+tmp_file.split("/")[-1]
          return tmp_file
      
      outfile=MAKETMP()
      
      extensions={"PNG":".png","PDF":".pdf","CYS":".cys","CYJS":".cyjs"}
      ext=extensions[filetype]
      
      response=cytoscape("view","fit content",host=host,port=port)
      response=cytoscape("view", "export" , \
                         {"options":filetype,\
                          "OutputFile":outfile},\
                        host=host,port=port)
      if host!='localhost':
          ssh = paramiko.SSHClient()
          ssh.set_missing_host_key_policy(paramiko.AutoAddPolicy())
          ssh.connect(host)
          ftp_client=ssh.open_sftp()
          ftp_client.get(outfile+ext,outfile+ext)
          ssh_stdin, ssh_stdout, ssh_stderr = ssh.exec_command("rm "+outfile+ext )
          
      img = WImage(filename=outfile+ext)
      if saveas:
          copyfile(outfile+ext,saveas)
      os.remove(outfile+ext)
      return img
docs: Checks the current network. 
      
      Note: works only on localhost
     
      :param filetype: file type, default="PNG" 
      :param saveas: /path/to/non/tmp/file.prefix
      :param host: cytoscape host address, default=cytoscape_host
      :param port: cytoscape port, default=1234
  
      :returns: an image