INNER CODE UNIT · Python

binnify

open2c/bioframe · src/bioframe/extras.py:125

def binnify(chromsizes, binsize, rel_ids=False):
    """
    Divide a genome into evenly sized bins.

    Parameters
    ----------
    chromsizes : Series
        pandas Series indexed by chromosome name with chromosome lengths in bp.

    binsize : int
        size of bins in bp

    Returns
    -------
    bintable : pandas.DataFrame with columns: 'chrom', 'start', 'end'.

    """

View source record →

📰 Research Paper
Loading…
⏳ Fetching content…