python/pymethylprocess/meffil_functions.py
def remove_sex(beta, array_type='450k'):
    """Remove non-autosomal cpgs from beta matrix.

    Parameters
    ----------
    array_type
        450k/850k array?
    """
    beta = robjects.r("""function (beta,array.type){
        featureset<-array.type
        autosomal.sites <- meffil.get.autosomal.sites(featureset)
        autosomal.sites <- intersect(autosomal.sites, rownames(beta))
        beta <- beta[autosomal.sites,]
        return(beta)
        }""")(beta,array_type)
    return beta
Remove non-autosomal cpgs from beta matrix.

    Parameters
    ----------
    array_type
        450k/850k array?
    
Remove non-autosomal cpgs from beta matrix.
Parameters


Remove non - autosomal cpgs from beta matrix . Parameters
def remove_sex(beta, array_type='450k'):
    beta = robjects.r("""function (beta,array.type){
        featureset<-array.type
        autosomal.sites <- meffil.get.autosomal.sites(featureset)
        autosomal.sites <- intersect(autosomal.sites, rownames(beta))
        beta <- beta[autosomal.sites,]
        return(beta)
        }""")(beta,array_type)
    return beta
def remove_sex ( beta , array_type = '450k' ) : beta = robjects . r ( """function (beta,array.type){
        featureset<-array.type
        autosomal.sites <- meffil.get.autosomal.sites(featureset)
        autosomal.sites <- intersect(autosomal.sites, rownames(beta))
        beta <- beta[autosomal.sites,]
        return(beta)
        }""" ) ( beta , array_type ) return beta
Remove non-autosomal cpgs from beta matrix.
Remove non - autosomal cpgs from beta matrix .
"""Remove non-autosomal cpgs from beta matrix.

    Parameters
    ----------
    array_type
        450k/850k array?
    """
beta
array_type