

def add_star(self, nodes, **attr):
    'Add a star.\n\n        The first node in nodes is the middle of the star.  It is connected\n        to all other nodes.\n\n        Parameters\n        ----------\n        nodes : iterable container\n            A container of nodes.\n        attr : keyword arguments, optional (default= no attributes)\n            Attributes to add to every edge in star.\n\n        See Also\n        --------\n        add_path, add_cycle\n\n        Examples\n        --------\n        >>> G = nx.Graph()   # or DiGraph, MultiGraph, MultiDiGraph, etc\n        >>> G.add_star([0,1,2,3])\n        >>> G.add_star([10,11,12],weight=2)\n\n        '
    nlist = list(nodes)
    v = nlist[0]
    edges = ((v, n) for n in nlist[1:])
    self.add_edges_from(self, **attr)

dataset/ETHPy150Open networkx/networkx/networkx/classes/tests/timingclasses.py TimingGraph.add_star/VarMisuse@53/286 `edges`->`self`