(self, f, sep=" ", eol="\n", *args, **kwds)
Writes the adjacency matrix of the graph to the given file

        All the remaining arguments not mentioned here are passed intact
        to L{Graph.get_adjacency}.

        @param f: the name of the file to be written.
        @param sep: the string that separates the matrix elements in a row
        @param eol: the string that separates the rows of the matrix. Please
          note that igraph is able to read back the written adjacency matrix
          if and only if this is a single newline character
Writes the adjacency matrix of the graph to the given file
Writes the adjacency matrix of the graph to the given file
def write_adjacency(self, f, sep=" ", eol="\n", *args, **kwds):
        """Writes the adjacency matrix of the graph to the given file

        All the remaining arguments not mentioned here are passed intact
        to L{Graph.get_adjacency}.

        @param f: the name of the file to be written.
        @param sep: the string that separates the matrix elements in a row
        @param eol: the string that separates the rows of the matrix. Please
          note that igraph is able to read back the written adjacency matrix
          if and only if this is a single newline character
        """
        if isinstance(f, str):
            f = open(f, "w")
        matrix = self.get_adjacency(*args, **kwds)
        for row in matrix:
            f.write(sep.join(map(str, row)))
            f.write(eol)
        f.close()
def write_adjacency ( self , f , sep = " " , eol = "\n" , * args , * * kwds ) : if isinstance ( f , str ) : f = open ( f , "w" ) matrix = self . get_adjacency ( * args , * * kwds ) for row in matrix : f . write ( sep . join ( map ( str , row ) ) ) f . write ( eol ) f . close ( )