Description Usage Arguments Details Value Author(s) References See Also Examples
View source: R/getLimmaInput.R
Fits the linear model log2(count+scalefac) = beta0 +
beta1*group + beta2*library.size + [optional confounders]
to each nucleotide. From these models, this function
constructs an object which can be directly passed to
getTstats
to obtain limma
's moderated t
statistics for each nucleotide, which we use as a measure
of strength of association between group and count
(expression). Reads coverage file from a SQLite database
(see makeDb
) and relies heavily on the limma
package, using lmFit
as the main workhorse.
1 2 3 |
dbfile |
Name/location (as character string) of database (usually ".db") file containing nucleotide by sample coverage. |
tablename |
Name of the table the database contains |
comparison |
Either |
group |
a 0/1 vector grouping the samples (columns) in the database. |
chunksize |
How many rows of the database should be processed at a time? |
adjustvars |
Optional matrix of adjustment variables (e.g. measured confounders, output from SVA, etc.) to use in fitting linear models to each nucleotide. |
colsubset |
Optional vector of column indices of the input file that denote samples you wish to include in analysis. Should NEVER include 1 (genomic position). |
scalefac |
A log transformation is used on the count tables, so zero counts present a problem. What number should we add to the entire matrix before running the models? Defaults to 32. |
nonzero |
If TRUE, use the median of only the nonzero counts as the library size adjustment. |
colmeds |
If NULL, the column medians are calculated
using |
It is assumed that the first column in the database is
called pos
and contains genomic position. Note that
group
must have the one fewer entries than the
database denoted by dbfile
has columns (or, if
colsubset is used, one fewer entries than the length of
colsubset). Also, adjustvars
must have the same
number of rows as group
has entries. Larger values
of chunksize
require more memory; smaller values of
chunksize
require more computation time.
A list with elements
ebobject |
A list of five
vectors ( |
pos |
A vector of the same length as those contained
in |
Alyssa Frazee
Smyth G (2004). "Linear models and empirical Bayes methods for assessing differential expression in microarray experiments." Statistical Applications in Genetics and Molecular Biology 3(1): Article 3.
1 | ## add example here when we have a vignette
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.