Learn R Programming

rGREAT (version 1.4.2)

submitGreatJob: Send requests to GREAT web server

Description

Send requests to GREAT web server

Usage

submitGreatJob(gr, bg = NULL,
    species               = "hg19",
    includeCuratedRegDoms = TRUE,
    bgChoice              = ifelse(is.null(bg), "wholeGenome", "data"),
    rule                  = c("basalPlusExt", "twoClosest", "oneClosest"),
    adv_upstream          = 5.0,
    adv_downstream        = 1.0,
    adv_span              = 1000.0,
    adv_twoDistance       = 1000.0,
    adv_oneDistance       = 1000.0,
    request_interval = 300,
    max_tries = 10,
    version = "default")

Arguments

gr
A GRanges object or a data frame which contains at least three columns (chr, start and end). Regions for test.
bg
A GRanges object or a data frame. Background regions if needed.
species
Species. "hg19", "mm10", "mm9", "danRer7" are supported in GREAT version 3.x.x and "hg19", "hg18", "mm9", "danRer7" are supported in GREAT version 2.x.x.
includeCuratedRegDoms
Whether to include curated regulatory domains.
bgChoice
How to define background. If it is set as data, bg should be set as well.
rule
How to associate genomic regions to genes. See 'details' section.
adv_upstream
Unit: kb, only used when rule is basalPlusExt
adv_downstream
Unit: kb, only used when rule is basalPlusExt
adv_span
Unit: kb, only used when rule is basalPlusExt
adv_twoDistance
Unit: kb, only used when rule is twoClosest
adv_oneDistance
Unit: kb, only used when rule is oneClosest
request_interval
Time interval for two requests. Default is 300 seconds.
max_tries
Maximum times trying to connect to GREAT web server.
version
version of GREAT. The value should be "3.0.0", "2.0.2". Shorten version numbers can also be used, such as using "3" or "3.0" is same as "3.0.0".

Value

  • A GreatJob-class class object which can be used to get results from GREAT server.

Details

Note it is not the standard GREAT API. This function directly send data to GREAT web server by HTTP POST.

Following text is copied from GREAT web site ( http://bejerano-test.stanford.edu/great/public/html/index.php )

Explanation of rule and settings with names started with 'adv_' (advanced settings):

[object Object],[object Object],[object Object]

See Also

GreatJob-class

Examples

Run this code
set.seed(123)
bed = circlize::generateRandomBed(nr = 1000, nc = 0)
job = submitGreatJob(bed)

# more parameters can be set for the job
job = submitGreatJob(bed, species = "mm9")
job = submitGreatJob(bed, bg, species = "mm9", bgChoise = "data")
job = submitGreatJob(bed, adv_upstream = 10, adv_downstream = 2, adv_span = 2000)
job = submitGreatJob(bed, rule = "twoClosest", adv_twoDistance = 2000)
job = submitGreatJob(bed, rule = "oneClosest", adv_oneDistance = 2000)

Run the code above in your browser using DataLab