From c4e09b75308d3fc57063ffb49b626a4771affeaf Mon Sep 17 00:00:00 2001 From: Dave Tang Date: Thu, 31 Oct 2024 08:38:01 +0000 Subject: [PATCH] Build site. --- docs/edger_de.html | 138 ++++++++++++++++++++++++++++++++++++++++++--- 1 file changed, 130 insertions(+), 8 deletions(-) diff --git a/docs/edger_de.html b/docs/edger_de.html index cba2d6b..0373403 100644 --- a/docs/edger_de.html +++ b/docs/edger_de.html @@ -520,15 +520,15 @@

2024-10-31

@@ -538,7 +538,7 @@

2024-10-31

The results in this page were generated with repository version -92b951c. +04948c5. See the Past versions tab to see a history of the changes made to the R Markdown and HTML files.

@@ -560,10 +560,6 @@

2024-10-31

Ignored: data/pbmc3k/ Ignored: r_packages_4.4.0/ -Untracked files: - Untracked: data/13970886_edger_res.csv - Untracked: rsem.merged.gene_counts.tsv -

Note that any generated files, e.g. HTML, png, CSS, etc., are not @@ -612,6 +608,40 @@

2024-10-31

Rmd +04948c5 + + +Dave Tang + + +2024-10-31 + + +Export edgeR results + + + + +html + + +cfbb929 + + +Dave Tang + + +2024-10-31 + + +Build site. + + + + +Rmd + + 92b951c @@ -799,6 +829,48 @@

DGEList

The input to edgeR is the DGEList object. The required inputs for creating a DGEList object is the count table and a grouping factor.

+
gene_counts |>
+  dplyr::select(starts_with("ERR")) |>
+  mutate(across(everything(), as.integer)) |>
+  as.matrix() -> gene_counts_mat
+
+row.names(gene_counts_mat) <- gene_counts$gene_id
+
+idx <- match(colnames(gene_counts_mat), my_metadata$run_id)
+colnames(gene_counts_mat) <- my_metadata$sample[idx]
+
+y <- DGEList(
+  counts = gene_counts_mat,
+  group = my_metadata$group[idx]
+)
+
+y
+
An object of class "DGEList"
+$counts
+                C2_norm C3_norm C5_norm C1_norm C1_cancer C2_cancer C3_cancer
+ENSG00000000003       2       6       5     374      1637       650      1015
+ENSG00000000005      19      40      28       0         1         0         0
+ENSG00000000419     268     273     428     489       637       879      1157
+ENSG00000000457     360     449     566     362       605       708       632
+ENSG00000000460     155     184     264      85       312       239       147
+                C5_cancer
+ENSG00000000003       562
+ENSG00000000005         0
+ENSG00000000419       729
+ENSG00000000457       478
+ENSG00000000460       156
+63135 more rows ...
+
+$samples
+           group lib.size norm.factors
+C2_norm   normal  4441588            1
+C3_norm   normal  5349291            1
+C5_norm   normal  7613422            1
+C1_norm   normal 15972904            1
+C1_cancer cancer 22329493            1
+C2_cancer cancer 29928921            1
+C3_cancer cancer 24891206            1
+C5_cancer cancer 23703606            1

Filtering to remove low counts

@@ -845,6 +917,34 @@

Normalisation for composition bias

library size replaces the original library size in all downstream analyses

+
y <- normLibSizes(y)
+y
+
An object of class "DGEList"
+$counts
+                C2_norm C3_norm C5_norm C1_norm C1_cancer C2_cancer C3_cancer
+ENSG00000000003       2       6       5     374      1637       650      1015
+ENSG00000000005      19      40      28       0         1         0         0
+ENSG00000000419     268     273     428     489       637       879      1157
+ENSG00000000457     360     449     566     362       605       708       632
+ENSG00000000460     155     184     264      85       312       239       147
+                C5_cancer
+ENSG00000000003       562
+ENSG00000000005         0
+ENSG00000000419       729
+ENSG00000000457       478
+ENSG00000000460       156
+37419 more rows ...
+
+$samples
+           group lib.size norm.factors
+C2_norm   normal  4431282    1.4420477
+C3_norm   normal  5337400    1.4377942
+C5_norm   normal  7594512    1.3836402
+C1_norm   normal 15964680    0.8389637
+C1_cancer cancer 22317658    0.8199077
+C2_cancer cancer 29912740    0.7972139
+C3_cancer cancer 24876336    0.8151023
+C5_cancer cancer 23693355    0.7798397

MDS

@@ -978,6 +1078,17 @@

Differential expression

+cfbb929 + + +Dave Tang + + +2024-10-31 + + + + 6aa4e2d @@ -1026,6 +1137,17 @@

Differential expression

+cfbb929 + + +Dave Tang + + +2024-10-31 + + + + 6aa4e2d