map_mrpr: map_mrpr() This function maps the scd and hsm sites onto...

View source: R/map_mrpr.R

map_mrprR Documentation

map_mrpr() This function maps the scd and hsm sites onto different genomic features (e.g. genes, exon, promoter, etc.)

Description

map_mrpr() This function maps the scd and hsm sites onto different genomic features (e.g. genes, exon, promoter, etc.)

Usage

map_mrpr(hsmrL, species, slabel, genome_ann, gnmsize, UTRflag, outfile)

Arguments

hsmrL

List of data frames with hsm rich and poor regions, as put out by

species

Label for the species being analyzed

slabel

Label for the sample

genome_ann

A list of GRanges objects that contains genome annotation.

gnmsize

Genome size

UTRflag

Numerical, indicating whether or not the annotation included UTRs (1 or 0)

outfile

If specified, then the result is saved in the specified file name.

Value

Data frames describing genes overlapping with methylation-rich and poor regions

Examples

  mydatf <- system.file("extdata","Am.dat",package="BWASPR")
  myparf <- system.file("extdata","Am.par",package="BWASPR")
  infiles <- setup_BWASPR(datafile=mydatf,parfile=myparf)
  asmblv <- infiles$parameters[infiles$parameters$Variable == "ASSEMBLYVERSION",2]
  gnmsize <- as.numeric(infiles$parameters[infiles$parameters$Variable == "GENOMESIZE",2])
  UTRflag <- as.numeric(infiles$parameters[infiles$parameters$Variable == "UTRFLAGSET",2])
  AmHE <- mcalls2mkobj(infiles$datafiles,species="Am",study="HE",
                       sample=list("forager","nurse"),replicate=c(0),
                       type="CpGhsm",mincov=1,assembly=asmblv
                      )
  hsmrL <- det_mrpr(AmHE[[1]],"Am_HE_fr",ddset=c(1,5),outfile="dst-Am_HE_fr.txt",nr2d=10L,doplots=TRUE)
  ginfo <- get_genome_annotation(infiles$parameters)
  map_mrpr(hsmrL,species="Am",slabel="forager_hsm",ginfo,gnmsize,UTRflag=UTRflag,
           outfile="AmHE-region.map.txt"
          )


BrendelGroup/BWASPR documentation built on June 2, 2025, 7:25 a.m.