hist_self_nonself: Plot histograms of self-self and self-nonself distances

Description Usage Arguments Details Value See Also Examples

View source: R/hist_self_nonself.R

Description

Plot histograms of self-self and self-nonself distances

Usage

1
hist_self_nonself(d, breaks = NULL, rug = TRUE, xlabel = "distance")

Arguments

d

A distance matrix

breaks

Histogram breaks (default is to use 100 intervals)

rug

If TRUE, use graphics::rug() to plot tick marks at the observed values, below the histograms.

xlabel

Label on x-axes (e.g., "similarity" vs "distance")

Details

We use the mfrow arg for graphics::par() to make a two-panel figure.

Value

None.

See Also

get_self(), get_nonself()

Examples

1
2
3
4
5
6
7
8
9
# align rows in the provided dataset, lineup2ex
aligned <- align_matrix_rows(lineup2ex$gastroc, lineup2ex$islet)
# find correlated columns
selected_genes <- (corr_betw_matrices(aligned[[1]], aligned[[2]], "paired") > 0.75)
# calculate correlation between rows
similarity <- corr_betw_matrices(t(lineup2ex$gastroc[,selected_genes]),
                                 t(lineup2ex$islet[,selected_genes]), "all")
# histograms of the self and non-self distances
hist_self_nonself(similarity)

lineup2 documentation built on June 15, 2021, 9:07 a.m.