Open BAREJAA opened 2 years ago
For this question -
"Create a new assay called “cpm” (Counts-Per-Million), which contains the result of dividing the counts matrix by the total counts in millions."
The course's answer is - assay(tung, "cpm") <- counts(tung)/tung$total_counts/1e6
Shouldn't it be - assay(tung, "cpm") <- sweep(counts(tung), 2, tung$total_counts, "/")/1e6
?
p.s. This is a wonderful course/book!!
For this question -
"Create a new assay called “cpm” (Counts-Per-Million), which contains the result of dividing the counts matrix by the total counts in millions."
The course's answer is - assay(tung, "cpm") <- counts(tung)/tung$total_counts/1e6
Shouldn't it be - assay(tung, "cpm") <- sweep(counts(tung), 2, tung$total_counts, "/")/1e6
?
p.s. This is a wonderful course/book!!