INNER CODE UNIT · Python

select_mask

open2c/bioframe · src/bioframe/ops.py:29

def select_mask(df, region, cols=None):
    """
    Return boolean mask for all genomic intervals that overlap a query range.

    Parameters
    ----------
    df : pandas.DataFrame

    region : str or tuple
        The genomic region to select from the dataframe in UCSC-style genomic
        region string, or triple (chrom, start, end).

    cols : (str, str, str) or None
        The names of columns containing the chromosome, start and end of the
        genomic intervals. The default values are 'chrom', 'start', 'end'.

    Returns
    -------

View source record →

📰 Research Paper
Loading…
⏳ Fetching content…