code: def graph(self, ig):
          
  
          res = copy.copy(self)
          res._edges = ig
          res._nodes = None
          return res
docs: Specify the node and edge data.
  
          :param ig: Graph with node and edge attributes.
          :type ig: NetworkX graph or an IGraph graph.
  
          :returns: Plotter.
          :rtype: Plotter.