exportResults-methods: Method exportResults

Description Usage Arguments Value Examples

Description

Method exportResults

Export the (Differential) Modification Peaks/Sites and their associated Statistics

Usage

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
exportResults(
  sep,
  format = c("CSV", "BED", "RDS"),
  table_style = c("bed", "granges"),
  save_dir = "exomepeaks_result",
  cut_off_pvalue = NULL,
  cut_off_padj = 0.1,
  cut_off_log2FC = 0,
  min_num_of_positive = 30,
  expected_direction = c("both", "hyper", "hypo"),
  inhibit_filter = FALSE,
  reads_count = TRUE,
  GC_sizeFactors = TRUE
)

## S4 method for signature 'SummarizedExomePeak'
exportResults(
  sep,
  format = c("CSV", "BED", "RDS"),
  table_style = c("bed", "granges"),
  save_dir = "exomePeak2_output",
  cut_off_pvalue = NULL,
  cut_off_padj = 0.1,
  cut_off_log2FC = 0,
  min_num_of_positive = 100,
  expected_direction = c("both", "hyper", "hypo"),
  inhibit_filter = FALSE,
  reads_count = TRUE,
  GC_sizeFactors = TRUE
)

Arguments

sep

a SummarizedExomePeak object.

format

a character for the exported format, could be a vector that contains c("CSV", "BED", "RDS").

CSV

export a comma separated values (CSV) table with the genomic location and LFC statistics.

BED

export a BEDGraph file with the score column = -log2(adjusted p value).

RDS

export the RDS file of the SummarizedExperiment object.

table_style

a character for the style of the CSV table being exported, could be one in c("bed","granges").

bed

the genomic locations in the table are represented by BEDgraph style.

granges

the genomic locations in the table are represented by GRanges style.

save_dir

a character for the name of the directory being saved; Default = "exomePeak2_output".

cut_off_pvalue

a numeric value for the p value cutoff in the exported result; Default = NULL.

cut_off_padj

a numeric value for the adjusted p value cutoff in the exported result; Default = 0.05.

cut_off_log2FC

a numeric value for the log2 fold change cutoff of the exported result, only the sites with abs(LFC) larger than this value are kept; Default = 0.

min_num_of_positive

a numeric value for the minimum number of reported sites. If the number of remaining sites is less than this number after filtering, additional sites will be reported by the increasing order of the p value to meet this number.

expected_direction

a character for the expected differential modification direction, could be one in c("hyper", "hypo", "both").

hyper

only report the peaks/sites with interactive LFC > 0.

hypo

only report the peaks/sites with interactive LFC < 0.

both

report the peaks/sites in both directions.

This argument is useful when the treated group involves the perturbation of a known writer or eraser protein; Default "both".

inhibit_filter

a logical of whether to remove all the filters, this option is useful when quantification on single based site annotation; Default = FALSE.

reads_count

a logical of whether to export the reads count for each sample; Default = TRUE.

GC_sizeFactors

a logical of whether to export the GC content correction size factors; Default = TRUE.

Value

none, a folder will be saved on the disk.

Examples

1
2
3
4
5
6
7
### Load the example SummarizedExomPeak object
f1 = system.file("extdata", "sep_ex_mod.rds", package="exomePeak2")

sep <- readRDS(f1)

### Save the modification peaks/sites statistics on the current directory.
exportResults(sep)

exomePeak2 documentation built on Nov. 8, 2020, 5:27 p.m.