Description Usage Arguments Value Author(s) Examples
Function for producing various figures corresponding to
the SigFuge functional data approach to studying RNA-seq
data as expression curves along base positions. The primary
input for the function is a read count matrix and
GRanges
. The default behavior is to identify
clusters based on applying SFlabels
to a normalized
version of the data produced by SFnormalize
.
If specified, the function will compute a p-value for the
significance of the labels by calling the SFpval
function.
1 2 3 4 5 |
data |
a d x n matrix or data.frame of read counts at d base positions for n samples. |
locusname |
a character string specifying gene or locus name to be used in figure title. |
annot |
a
|
flip.fig |
an indicator whether to flip the plotting
direction of the locus if |
label.exon |
an indicator whether to print the exon boundaries to the figure. |
print.n |
an indicator whether to print cluster sizes. |
data.labels |
a n x 1 vector of class labels to use instead of calcuating SigFuge labels |
label.colors |
a K x 3 matrix of
RBG colors specifying cluster colors for K clusters.
|
flag |
a n x 1 logical vector of
samples flagged as low expression. If |
lplots |
a specification of which figures to output
|
log10 |
an indicator whether the y-axis (read depth) should be log10 transformed. Default is to plot on log-scale. |
summary.type |
a character string specifying which summary statistic should be used when plotting clusters in lplots == 2, 3, and 5. Options: "median" (default) or "mean". |
savestr |
a string specifying the file name for
resulting figures. Extensions can also be specified in
|
titlestr |
a string specifying figure title. If
unspecified, default is
|
pval |
an indicator whether the |
SFfigure
returns a figure that is saved to the
current working directory if a savestr
is
specified. Else, a list containing the plots is returned.
Patrick Kimes <pkimes@live.unc.edu>
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 | # load data
data(geneAnnot)
data(geneDepth)
# only use first 50 samples
mdata <- geneDepth[,1:50]
# make plot
locusname <- "CDKN2A"
SFfigure(mdata, locusname, geneAnnot, flag=1,
lplots=3, savestr=paste0(locusname,".pdf"), titlestr="CDKN2A locus, LUSC samples",
pval=1)
mySFs <- SFfigure(mdata, locusname, geneAnnot, flag=1,
lplots=1, savestr=c(), titlestr="CDKN2A locus, LUSC samples not saved",
pval=0)
mySFs$plot1
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.