Description Usage Arguments Value See Also Examples
construct_contrasts
is a wrapper function to
limma::makeContrasts
. It allows to specify which comparisons from
the linear model fit are to be extracted.
1 2 3 4 | construct_contrasts(design, ...)
## Default S3 method:
construct_contrasts(design, ...)
|
design |
A design matrix. See |
... |
A set of contrasts that should be constructed, preferably in
the format See |
An object of class matrix with columns corresponding to contrasts
rnaseq
, gather_counts
show_counts
limma_dge
edger_dge
construct_design
write_dge
as.dgelist
as.eset
density_plot
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 | path = system.file("tests", package="ganalyse")
# ----- fpkm ----- #
fpkm_path = file.path(path, "fpkm", "annotation.txt")
fpkm_obj = rnaseq(fpkm_path, format="fpkm", experiment="sample")
fpkm_counts = gather_counts(fpkm_obj, by="gene-id", log_base=2L)
fpkm_design = construct_design(fpkm_counts, ~ 0 + condition)
fpkm_contrasts = construct_contrasts(
design = fpkm_design,
treatA.vs.control = conditiontreatA-conditioncontrol,
treatB.vs.control = conditiontreatB-conditioncontrol
)
# ----- raw ----- #
raw_path = file.path(path, "raw", "annotation.txt")
raw_obj = rnaseq(raw_path, format="raw", experiment="sample")
raw_counts = gather_counts(raw_obj, by="gene-id", threshold=1L)
raw_design = construct_design(raw_counts, ~ 0 + condition)
raw_contrasts = construct_contrasts(
design = raw_design,
treatA.vs.control = conditiontreatA-conditioncontrol,
treatB.vs.control = conditiontreatB-conditioncontrol
)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.