nonOverlapGenes: Calculates Genes that are near to the SV region

View source: R/OverlappingGenes.r

nonOverlapGenesR Documentation

Calculates Genes that are near to the SV region

Description

Calculates Genes that are near to the SV region

Usage

nonOverlapGenes(
  bed,
  chrom,
  startpos,
  chrom2,
  endpos,
  svid,
  n = 3,
  SVTyp,
  bperrorindel = 3000,
  bperrorinvtrans = 50000
)

Arguments

bed

Text Bionano Bed file.

chrom

character SVmap chromosome.

startpos

numeric starting position of the breakpoints.

chrom2

character SVmap 2nd chromosome.

endpos

numeric end position of the breakpoints.

svid

numeric Structural variant identifier (Bionano generated).

n

numeric Number of genes to report which are nearest to the breakpoint. Default is 3.

SVTyp

Character. Type of SV.

bperrorindel

Numeric. base pair error indel.

bperrorinvtrans

Numeric. base pair error invtranslocation.

Value

Data Frame. Contains the SVID,Gene name,strand information and Distance from the SV covered.

Examples

smapName="GM24385_Ason_DLE1_VAP_trio5.smap"
smap = system.file("extdata", smapName, package="nanotatoR")
bedFile <- system.file("extdata", "HomoSapienGRCH19_lift37.bed", 
       package="nanotatoR")
bed<-buildrunBNBedFiles(bedFile,returnMethod="dataFrame")
smap<-readSMap_DLE(smap, input_fmt_smap = "Text")
chrom<-smap$RefcontigID1
chrom2 <- smap$RefcontigID2
startpos<-smap$RefStartPos
endpos<-smap$RefEndPos
if (length(grep("SVIndex",names(smap)))>0){
       svid <- smap$SVIndex
   }else{
    svid <- smap$SmapEntryID
    }
SVTyp <- smap$Type
n<-3
nonOverlapGenes(bed = bed, chrom = chrom, startpos = startpos, 
endpos = endpos, svid = svid, chrom2 = chrom2, SVTyp = SVTyp,
   bperrorindel = 3000, bperrorinvtrans = 50000, n = 3)

VilainLab/nanotatoR documentation built on Aug. 3, 2024, 12:46 a.m.