class_docstr: Graph drawer that sends/receives graphs to/from Cytoscape using
  CytoscapeRPC.
  
  This graph drawer cooperates with U{Cytoscape<http://www.cytoscape.org>}
  using U{CytoscapeRPC<http://wiki.nbic.nl/index.php/CytoscapeRPC>}.
  You need to install the CytoscapeRPC plugin first and start the
  XML-RPC server on a given port (port 9000 by default) from the
  appropriate Plugins submenu in Cytoscape.
  
  Graph, vertex and edge attributes are transferred to Cytoscape whenever
  possible (i.e. when a suitable mapping exists between a Python type
  and a Cytoscape type). If there is no suitable Cytoscape type for a
  Python type, the drawer will use a string attribute on the Cytoscape
  side and invoke C{str()} on the Python attributes.
  
  If an attribute to be created on the Cytoscape side already exists with
  a different type, an underscore will be appended to the attribute name
  to resolve the type conflict.
  
  You can use the C{network_id} attribute of this class to figure out the
  network ID of the last graph drawn with this drawer.
docstr: Returns a Cytoscape type that can be used to represent all the
  values in C{values} and an appropriately converted copy of C{values} that
  is suitable for an XML-RPC call.  Note that the string type in
  Cytoscape is used as a catch-all type; if no other type fits, attribute
  values will be converted to string and then posted to Cytoscape.
  
  C{None} entries are allowed in C{values}, they will be ignored on the
  Cytoscape side.
docstr_tok: ["Returns","a","Cytoscape","type","that","can","be","used","to","represent","all","the","values","in","C","{","values","}","and","an","appropriately","converted","copy","of","C","{","values","}","that","is","suitable","for","an","XML-RPC","call",".","Note","that","the","string","type","in","Cytoscape","is","used","as","a","catch-all","type",";","if","no","other","type","fits",",","attribute","values","will","be","converted","to","string","and","then","posted","to","Cytoscape",".","C","{","None","}","entries","are","allowed","in","C","{","values","}",",","they","will","be","ignored","on","the","Cytoscape","side","."]
code: def infer_cytoscape_type(values):
      """Returns a Cytoscape type that can be used to represent all the
      values in C{values} and an appropriately converted copy of C{values} that
      is suitable for an XML-RPC call.  Note that the string type in
      Cytoscape is used as a catch-all type; if no other type fits, attribute
      values will be converted to string and then posted to Cytoscape.
  
      C{None} entries are allowed in C{values}, they will be ignored on the
      Cytoscape side.
      """
      types = [type(value) for value in values if value is not None]
      if all(t == bool for t in types):
          return "BOOLEAN", values
      if all(issubclass(t, (int, int)) for t in types):
          return "INTEGER", values
      if all(issubclass(t, float) for t in types):
          return "FLOATING", values
      return "STRING", [
          str(value) if not isinstance(value, str) else value
          for value in values
      ]
  
file_path: python-igraph/src/igraph/drawing/graph.py
imports: from warnings import warn
  from igraph.drawing.baseclasses import AbstractGraphDrawer, AbstractXMLRPCDrawer
label_desc: Use image node_id 4 for calling the CytoscapeGraphDrawer obj's underlying member method code with example usage: obj.infer_cytoscape_type(values) and returns: str,  unknown, str,  values, str,  values, str,  values