DISTAL-Object {RGMQL} | R Documentation

## DISTAL object class constructor

### Description

This class constructor is used to create instances of DISTAL object to be used in GMQL JOIN operations (RGMQL merge functions) that use genometric predicate parameter requiring distal condition on value

### Usage

    DL(value)

    DG(value)

    DLE(value)

    DGE(value)

    MD(value)

    UP()

    DOWN()

### Arguments

`value` | string identifying distance between genomic regions in base pair

### Details

- DL: It denotes the less distance clause, which selects all the regions of a joined experiment dataset sample such that their distance from the anchor region of the joined reference dataset sample is less than 'value' bases.

- DLE: It denotes the less equal distance clause, which selects all the regions of a joined experiment dataset sample such that their distance from the anchor region of the joined reference dataset sample is less than, or equal to, 'value' bases.

- DG: It denotes the great distance clause, which selects all the regions of a joined experiment dataset sample such that their distance from the anchor region of the joined reference dataset sample is greater than 'value' bases.

- DGE: It denotes the great equal distance clause, which selects all the regions of a joined experiment dataset sample such that their distance from the anchor region of the joined reference dataset sample is greater than, or equal to, 'value' bases.

- MD: It denotes the minimum distance clause, which selects the first 'value' regions of the joined experiment at minimial distance from the anchor region of the joined reference dataset sample.

- UP: It denotes the upstream direction of the genome. It makes predicates to be hold on the upstream of the regions of the joined reference dataset sample. UP is true when region of the joined experiment dataset sample is in the upstream genome of the anchor region of the joined reference dataset sample. When this clause is not present, distal conditions apply to both directions of the genome.

- DOWN: It denotes the downstream direction of the genome. It makes predicates to be hold on the downstream of the regions of the joined reference dataset sample. DOWN is true when region of the joined experiment dataset sample is in the downstream genome of the anchor region of the joined reference dataset sample. When this clause is not present, distal conditions apply to both directions of the genome.

### Value

Distal object

### Examples

    ## This statement initializes and runs the GMQL server for local execution
    ## and creation of results on disk. Then, with system.file() it defines
    ## the path to the folders "DATASET" and "DATASET_GDM" in the subdirectory
    ## "example" of the package "RGMQL", and opens such folders as a GMQL
    ## datasets named "TSS" and "HM", respectively, using CustomParser

    init_gmql()
    test_path <- system.file("example", "DATASET", package = "RGMQL")
    test_path2 <- system.file("example", "DATASET_GDM", package = "RGMQL")
    TSS = read_gmql(test_path)
    HM = read_gmql(test_path2)

    ## Given a dataset HM and one called TSS with a sample including
    ## Transcription Start Site annotations, this statement  searches for those
    ## regions of HM that are at a minimal distance from a transcription
    ## start site (TSS) and takes the first/closest one for each TSS, provided
    ## that such distance is lesser than 1200 bases and joined TSS and HM
    ## samples are obtained from the same provider (joinby clause).

    join_data = merge(TSS, HM,
        genometric_predicate = list(MD(1), DL(1200)), conds("provider"),
        region_output = "RIGHT")

    ## Given a dataset HM and one called TSS with a sample including
    ## Transcription Start Site annotations, this statement searches for those
    ## regions of HM that are downstream and at a minimal distance from a
    ## transcription start site (TSS) and takes the first/closest one for each
    ## TSS, provided that such distance is greater than 12K bases and joined
    ## TSS and HM samples are obtained from the same provider (joinby clause).

    join_data = merge(TSS, HM,
        genometric_predicate = list(MD(1), DGE(12000), DOWN()),
        conds("provider"), region_output = "RIGHT")

[Package RGMQL version 1.2.0 Index]