multiSetMEs(WGCNA)
multiSetMEs()所属R语言包:WGCNA
Calculate module eigengenes.
计算模块特征基因。
译者:生物统计家园网 机器人LoveR
描述----------Description----------
Calculates module eigengenes for several sets.
计算模块特征基因几套。
用法----------Usage----------
multiSetMEs(exprData,
colors,
universalColors = NULL,
useSets = NULL,
useGenes = NULL,
impute = TRUE,
nPC = 1,
align = "along average",
excludeGrey = FALSE,
grey = ifelse(is.null(universalColors), ifelse(is.numeric(colors), 0, "grey"),
ifelse(is.numeric(universalColors), 0, "grey")),
subHubs = TRUE,
trapErrors = FALSE,
returnValidOnly = trapErrors,
softPower = 6,
verbose = 1, indent = 0)
参数----------Arguments----------
参数:exprData
Expression data in a multi-set format (see checkSets). A vector of lists, with each list corresponding to one microarray dataset and expression data in the component data, that is expr[[set]]$data[sample, probe] is the expression of probe probe in sample sample in dataset set. The number of samples can be different between the sets, but the probes must be the same.
表达在多集的格式的数据(见checkSets)。一个向量的列表,每个列表对应于一个芯片数据集和表达数据的组件data,expr[[set]]$data[sample, probe]的表达探针probe样品中sample数据集set。集合之间的样本的数目可以是不同的,但探针必须是相同的。
参数:colors
A matrix of dimensions (number of probes, number of sets) giving the module assignment of each gene in each set. The color "grey" is interpreted as unassigned.
尺寸(数目的探针,集数)A矩阵的模块分配给每个集合中的每一个基因。 “灰”的颜色被解释为未分配。
参数:universalColors
Alternative specification of module assignment. A single vector of length (number of probes) giving the module assignment of each gene in all sets (that is the modules are common to all sets). If given, takes precedence over color.
另一种规格的模块分配。一个单一的矢量长度(数目的探针)的模块分配给每个基因在所有集合(即模块是共同的所有套组)。如果给定的优先级高于color。
参数:useSets
If calculations are requested in (a) selected set(s) only, the set(s) can be specified here. Defaults to all sets.
如果计算只要求(a)中选定的一组(S),集(S),可以在这里指定。默认为所有集合。
参数:useGenes
Can be used to restrict calculation to a subset of genes (the same subset in all sets). If given, validColors in the returned list will only contain colors for the genes specified in useGenes.
可用于限制计算的基因的一个子集(所有套组中的相同的子集)。如果给出,validColors在返回列表中只会包含的基因在useGenes的颜色。
参数:impute
Logical. If TRUE, expression data will be checked for the presence of NA entries and if the latter are present, numerical data will be imputed, using function impute.knn and probes from the same module as the missing datum. The function impute.knn uses a fixed random seed giving repeatable results.
逻辑。如果TRUE,表达数据进行检查NA项的存在,如果是后者,数值数据进行推算,使用相同的模块中的函数impute.knn和探针丢失的数据。函数impute.knn使用一个固定的随机种子,可重复的结果。
参数:nPC
Number of principal components to be calculated. If only eigengenes are needed, it is best to set it to 1 (default). If variance explained is needed as well, use value NULL. This will cause all principal components to be computed, which is slower.
主成分,以计算数目。如果只特征基因是必要的,最好是将其设置为1(默认值)。需要说明的是,如果方差为好,利用价值NULL。这将导致所有主要组件来计算,这是慢。
参数:align
Controls whether eigengenes, whose orientation is undetermined, should be aligned with average expression (align = "along average", the default) or left as they are (align = ""). Any other value will trigger an error.
控制的特征基因,其方向是不确定的,是否应与平均表达(align = "along average",默认值),或离开了,因为他们是(align = "")。任何其他值将触发一个错误。
参数:excludeGrey
Should the improper module consisting of 'grey' genes be excluded from the eigengenes?
不当模块组成的“灰色”基因被排除的特征基因?
参数:grey
Value of colors or universalColors (whichever applies) designating the improper module. Note that if the appropriate colors argument is a factor of numbers, the default value will be incorrect.
colors或universalColors(以适用者为准)指定的不正确模块的价值。需要注意的是,如果合适的颜色参数是一个因素的数字,默认值将是不正确的。
参数:subHubs
Controls whether hub genes should be substituted for missing eigengenes. If TRUE, each missing eigengene (i.e., eigengene whose calculation failed and the error was trapped) will be replaced by a weighted average of the most connected hub genes in the corresponding module. If this calculation fails, or if subHubs==FALSE, the value of trapErrors will determine whether the offending module will be removed or whether the function will issue an error and stop.
控制中心基因是否应替代缺失的特征基因。如果TRUE,每个的失踪eigengene(即,eigengene其计算失败,该错误被困住)将取代的加权平均最在相应的模块连接的集线器基因。如果此计算失败,或者如果subHubs==FALSE,trapErrors将决定是否将被删除或有问题的模块的功能是否会发出一个错误,停止。
参数:trapErrors
Controls handling of errors from that may arise when there are too many NA entries in expression data. If TRUE, errors from calling these functions will be trapped without abnormal exit. If FALSE, errors will cause the function to stop. Note, however, that subHubs takes precedence in the sense that if subHubs==TRUE and trapErrors==FALSE, an error will be issued only if both the principal component and the hubgene calculations have failed.
控制处理时可能出现的有太多NA中的表达数据的条目的错误。如果TRUE,调用这些函数的错误将被困无异常退出。如果FALSE,错误会导致停止的功能。但是,请注意,这subHubs的优先级在这个意义上,如果subHubs==TRUE和trapErrors==FALSE,错误将只有发行的主要组分和hubgene的的计算方法都失败了。
参数:returnValidOnly
Boolean. Controls whether the returned data frames of module eigengenes contain columns corresponding only to modules whose eigengenes or hub genes could be calculated correctly in every set (TRUE), or whether the data frame should have columns for each of the input color labels (FALSE).
布尔值。返回的数据框模块特征基因是否包含只有对应的模块,其特征基因或集线器的基因可以被正确地计算在每一个组(列的控件TRUE),或数据框是否应该有每个输入彩色标签的列,用于(FALSE“)。
参数:softPower
The power used in soft-thresholding the adjacency matrix. Only used when the hubgene approximation is necessary because the principal component calculation failed. It must be non-negative. The default value should only be changed if there is a clear indication that it leads to incorrect results.
软阈值的邻接矩阵中使用的电力。仅用于时,的hubgene近似是必要的,因为主要成分计算失败。它必须为非负数。只应更改的默认值,如果有一个明显的迹象表明它会导致不正确的结果。
参数:verbose
Controls verbosity of printed progress messages. 0 means silent, up to (about) 5 the verbosity gradually increases.
控制冗长的印刷进度消息。 0表示沉默,同比增长约5的详细程度逐渐增加。
参数:indent
A single non-negative integer controlling indentation of printed messages. 0 means no indentation, each unit above that adds two spaces.
一个单一的非负整数控制缩进印刷信息。 0表示无压痕,上述各单位,增加了两个空间。
Details
详细信息----------Details----------
This function calls moduleEigengenes for each set in exprData.
这个函数调用moduleEigengenes为每一组中exprData。
Module eigengene is defined as the first principal component of the expression matrix of the corresponding module. The calculation may fail if the expression data has too many missing entries. Handling of such errors is controlled by the arguments subHubs and trapErrors. If subHubs==TRUE, errors in principal component calculation will be trapped and a substitute calculation of hubgenes will be attempted. If this fails as well, behaviour depends on trapErrors: if TRUE, the offending module will be ignored and the return value will allow the user to remove the module from further analysis; if FALSE, the function will stop. If universalColors is given, any offending module will be removed from all sets (see validMEs in return value below).
模块eigengene被定义为第一主成分的表达相应的模块的矩阵。如果表达式的数据有太多缺少的项,计算可能会失败。这样的错误处理控制的参数subHubs和trapErrors。如果subHubs==TRUE,主成分计算的错误,将被困住将尝试和替代的hubgenes计算。如果失败,那么,行为取决于trapErrors如果TRUE,有问题的模块将被忽略,并且返回值将允许用户删除的模块,进一步的分析; FALSE ,该功能将停止。如果universalColors,任何违规的模块将被删除所有集合(见validMEs在下面的返回值)。
From the user's point of view, setting trapErrors=FALSE ensures that if the function returns normally, there will be a valid eigengene (principal component or hubgene) for each of the input colors. If the user sets trapErrors=TRUE, all calculational (but not input) errors will be trapped, but the user should check the output (see below) to make sure all modules have a valid returned eigengene.
从用户的角度来看,设置trapErrors=FALSE确保,如果函数返回正常,将是一个有效的eigengene(主成分或hubgene)对每个输入的颜色。如果用户设置trapErrors=TRUE,所有calculational的(而不是输入)错误将被困人员,但用户应该检查输出(见下文),以确保所有模块都有一个有效eigengene。
While the principal component calculation can fail even on relatively sound data (it does not take all that many "well-placed" NA to torpedo the calculation), it takes many more irregularities in the data for the hubgene calculation to fail. In fact such a failure signals there likely is something seriously wrong with the data.
虽然主成分的计算可能会失败,即使在比较完善的数据(它并不需要那么多的“占尽天时地利”NA鱼雷计算),它需要更多的违规行为中的数据计算,以hubgene失败的。事实上,这样的故障信号,有可能是严重错误的数据。
值----------Value----------
A vector of lists similar in spirit to the input exprData. For each set there is a list with the following components:
输入exprData的矢量列表类似的精神。对于每一组有与以下组件的列表:
参数:data
Module eigengenes in a data frame, with each column corresponding to one eigengene. The columns are named by the corresponding color with an "ME" prepended, e.g., MEturquoise etc. Note that, when trapErrors == TRUE and returnValidOnly==FALSE, this data frame also contains entries corresponding to removed modules, if any. (validMEs below indicates which eigengenes are valid and allOK whether all module eigengens were successfully calculated.)
模块中的数据框的特征基因,与一个eigengene各列对应。列被命名为相应的颜色与"ME"前缀,例如,MEturquoise等等。注意的是,当trapErrors == TRUE和returnValidOnly==FALSE,这个数据框中也包含对应的条目删除模块,如果有的话。 (validMEs以下特征基因是有效的,allOK是否成功地计算了所有模块eigengens的)。
参数:averageExpr
If align == "along average", a dataframe containing average normalized expression in each module. The columns are named by the corresponding color with an "AE" prepended, e.g., AEturquoise etc.
如果align == "along average",一个数据框,在每个模块的平均归一化表达。列被命名为相应的颜色"AE"前缀,例如,AEturquoise等
参数:varExplained
A dataframe in which each column corresponds to a module, with the component varExplained[PC, module] giving the variance of module module explained by the principal component no. PC. This is only accurate if all principal components have been computed (input nPC = NULL). At most 5 principal components are recorded in this dataframe.
甲数据框,其中每一列对应于一个模块,与组分varExplained[PC, module]给模块的方差module由主成分没有解释。 PC。这是唯一正确的,如果所有的主要组成部分已计算(输入nPC = NULL)。至多为5主成分记录在此数据框。
参数:nPC
A copy of the input nPC.
的副本输入nPC。
参数:validMEs
A boolean vector. Each component (corresponding to the columns in data) is TRUE if the corresponding eigengene is valid, and FALSE if it is invalid. Valid eigengenes include both principal components and their hubgene approximations. When returnValidOnly==FALSE, by definition all returned eigengenes are valid and the entries of validMEs are all TRUE.
一个布尔值的向量。每一个组件(对应列在data)TRUE如果相应的eigengene是有效的,和FALSE,如果它是无效的。有效的特征基因本金的组件及其hubgene的的近似。当returnValidOnly==FALSE,定义,所有返回的特征基因的条目是有效的,validMEs都是TRUE。
参数:validColors
A copy of the input colors (universalColors if set, otherwise colors[, set]) with entries corresponding to invalid modules set to grey if given, otherwise 0 if the appropriate input colors are numeric and "grey" otherwise.
输入颜色的副本(universalColors如果设置,否则colors[, set])与对应的条目无效的模块设置成grey如果给定,否则为0,如果相应的输入颜色数字和“灰色“,否则。
参数:allOK
Boolean flag signalling whether all eigengenes have been calculated correctly, either as principal components or as the hubgene approximation. If universalColors is set, this flag signals whether all eigengenes are valid in all sets.
布尔所有特征基因是否已正确计算,无论是作为主要成分或的hubgene近似的标志信号。如果universalColors设置,这个标志表明是否在所有集合的所有特征基因是有效的。
参数:allPC
Boolean flag signalling whether all returned eigengenes are principal components. This flag (as well as the subsequent ones) is set independently for each set.
布尔标志,信号是否所有返回的特征基因的主要组成部分。此标志(以及其后的)被设置为每一组独立。
参数:isPC
Boolean vector. Each component (corresponding to the columns in eigengenes) is TRUE if the corresponding eigengene is the first principal component and FALSE if it is the hubgene approximation or is invalid.
布尔向量。每个成分(对应于中的列eigengenes)TRUE如果相应的eigengene是第一主成分和FALSE如果它是hubgene的近似或无效。
参数:isHub
Boolean vector. Each component (corresponding to the columns in eigengenes) is TRUE if the corresponding eigengene is the hubgene approximation and FALSE if it is the first principal component or is invalid.
布尔向量。每个成分(对应于中的列eigengenes)TRUE如果相应的eigengene是的hubgene的近似和FALSE,如果它是第一主成分,或者是无效的。
参数:validAEs
Boolean vector. Each component (corresponding to the columns in eigengenes) is TRUE if the corresponding module average expression is valid.
布尔向量。每个组件(中的列对应eigengenes)TRUE如果相应的模块的平均表达是有效的。
参数:allAEOK
Boolean flag signalling whether all returned module average expressions contain valid data. Note that returnValidOnly==TRUE does not imply allAEOK==TRUE: some invalid average expressions may be returned if their corresponding eigengenes have been calculated correctly.
布尔标志,信号,所有返回的模块平均表达式是否包含有效的数据。请注意这returnValidOnly==TRUE并不意味着allAEOK==TRUE:一些无效的平均表现形式可能会被退回,如果相应的的特征基因已正确计算。
(作者)----------Author(s)----------
Peter Langfelder, <a href="mailtoeter.Langfelder@gmail.com">eter.Langfelder@gmail.com</a>
参见----------See Also----------
moduleEigengenes
moduleEigengenes
转载请注明:出自 生物统计家园网(http://www.biostatistic.net)。
注:
注1:为了方便大家学习,本文档为生物统计家园网机器人LoveR翻译而成,仅供个人R语言学习参考使用,生物统计家园保留版权。
注2:由于是机器人自动翻译,难免有不准确之处,使用时仔细对照中、英文内容进行反复理解,可以帮助R语言的学习。
注3:如遇到不准确之处,请在本贴的后面进行回帖,我们会逐渐进行修订。
|