make_se_test | R Documentation |
Make SummarizedExperiment test data
make_se_test(
ngroups = 2,
nreps = 3,
nrow = 50,
multiplier = 1,
offset = 7,
hit_fraction = 1/2,
hit_max = 2.8,
noise_factor = 1,
seed = 123,
assay_name = "counts",
sparsity = 0,
verbose = FALSE,
...
)
ngroups |
|
nrow |
|
multiplier |
|
offset |
|
hit_fraction |
|
hit_max |
|
noise_factor |
|
seed |
|
assay_name |
|
sparsity |
|
verbose |
|
... |
additional arguments are ignored. |
mreps |
|
SummarizedExperiment
object
Other jamses SE utilities:
se_collapse_by_column()
,
se_collapse_by_row()
,
se_detected_rows()
,
se_normalize()
,
se_rbind()
,
se_to_rowcoldata()
se <- make_se_test();
heatmap_se(se)
heatmap_se(se, controlSamples=1:3)
se <- make_se_test(ngroups=3, assay_name="expression");
heatmap_se(se, apply_hm_column_title=TRUE)
heatmap_se(se, controlSamples=1:3, control_label="versus A", apply_hm_column_title=TRUE)
se <- make_se_test(ngroups=3, assay_name="expression", nreps=c(3, 5, 4));
heatmap_se(se, controlSamples=1:3, control_label="versus A", apply_hm_column_title=TRUE)
se <- make_se_test(ngroups=3, assay_name="expression", nreps=c(3, 5, 4), hit_max=4);
heatmap_se(se, controlSamples=1:3, control_label="versus A", apply_hm_column_title=TRUE)
sedesign <- groups_to_sedesign(SummarizedExperiment::colData(se)[, "group", drop=FALSE])
plot_sedesign(sedesign)
sestats <- se_contrast_stats(se=se, sedesign=sedesign, assay_names="expression")
plot_sedesign(sedesign, sestats=sestats,
contrast_style="none", sestats_style="label")
heatmap_se(se, controlSamples=1:3, control_label="versus A",
column_split="group",
apply_hm_column_title=TRUE, sestats=sestats, color_max=5)
if (jamba::check_pkg_installed("venndir")) {
venndir::venndir(hit_array_to_list(sestats), overlap_type="each")
venndir::venndir(hit_array_to_list(sestats), overlap_type="each", proportional=TRUE)
venndir::venndir(hit_array_to_list(sestats), overlap_type="each", show_labels="ncs")
}
# demonstrate sparsity
se2 <- make_se_test(sparsity=c(0.5, 0));
hm2a <- heatmap_se(se2,
column_title="global centered\nall values shown")
# when centering versus a sparse control group, some values can be lost:
hm2b <- heatmap_se(se2, controlSamples=1:3,
column_title="centered vs A\nsome values become NA")
hm2a + hm2b
# use naControlFloor
hm2c <- heatmap_se(se2,
column_title="centered vs A\nnaControlFloor=7",
naControlFloor=7, naControlAction="floor", controlSamples=1:3)
hm2a + hm2b + hm2c
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.