tspc.cv(TSPC)
tspc.cv()所属R语言包:TSPC
Cross-validation
交叉验证
译者:生物统计家园网 机器人LoveR
描述----------Description----------
This function uses a form of cross-validation to estimate the optimal feature threshold in supervised principal components
此功能使用交叉验证的一种形式监督的主要成分估计的最优的特征阈值
用法----------Usage----------
tspc.cv(fit, data, seed = 123, topfea = TRUE, n.topfea = 1000, n.threshold = 20, n.fold = NULL, folds = NULL, n.components = 1, min.features = 5, max.features = nrow(data$x[[1]]), type = "survival")
参数----------Arguments----------
参数:fit
Object returned by tspc.train
返回的对象tspc.train
参数:data
Data object of form described in tspc.train documentation
在tspc.train文档的形式描述的数据对象
参数:seed
A Numeric number
一个数字号码
参数:topfea
If it is TRUE, then the tuning paparmeter is the number of features
如果是TRUE,那么的调整paparmeter是一些功能
参数:n.topfea
Maximum number of features used as the tuning parameter
作为调整参数的最大数量的功能
参数:n.threshold
Number of thresholds, when using the number of thresholds as a tuning parameter
数阈值时,使用的阈值的数目作为一个调谐参数
参数:n.fold
Number of cross-validation folds
交叉验证的褶皱数目
参数:folds
Lists of indices of cross-validation folds (optional)
指数的交叉验证倍数列表(可选)
参数:n.components
Number of cross-validation components to use: 1,2 or 3.
交叉验证组件使用的号码:1,2或3。
参数:min.features
Minimum number of features to include, in determining range for threshold. Default 5.
最小的功能,包括,在确定的阈值范围。默认值5。
参数:max.features
Maximum number of features to include, in determining range for threshold. Default is total number of features in the dataset.
最大的功能,包括,在确定的阈值范围。默认值是总的数据集的功能。
参数:type
"survival" or "regression"
“生存”或“回归”
Details
详细信息----------Details----------
This function uses a form of cross-validation to estimate the optimal feature threshold.
此功能使用某种形式的交叉验证估计最优的特征阈值。
值----------Value----------
list(thresholds = thresholds, n.threshold = n.threshold, nonzero = nonzero, scor = scor, scor.lower = scor.lower, scor.upper = scor.upper, folds = folds, n.fold = n.fold, featurescores.folds = featurescores.folds, type = type) <table summary="R valueblock"> <tr valign="top"><td>thresholds </td> <td> Vector of thresholds considered</td></tr> <tr valign="top"><td>n.threshold</td> <td> Number of thresholds</td></tr> <tr valign="top"><td>nonzero</td> <td> Number of features exceeding each value of the threshold</td></tr> <tr valign="top"><td>scor</td> <td> Full CV scores</td></tr> <tr valign="top"><td>scor.lower</td> <td> Full CV scores minus one standard error of scores</td></tr> <tr valign="top"><td>scor.upper</td> <td> Full CV scores plus one standard error of scores</td></tr> <tr valign="top"><td>folds</td> <td> Indices of CV folds used</td></tr> <tr valign="top"><td>n.fold</td> <td> Number of folds used in the cross-validation</td></tr> <tr valign="top"><td>featurescores.folds</td> <td> Feature scores for each fold</td></tr> <tr valign="top"><td>type </td> <td> problem type</td></tr> </table>
列表(阈值=阈值,n.threshold = n.threshold,非零=非零,打分打分,scor.lower = scor.lower,scor.upper = scor.upper,层层叠叠的褶皱,n.fold = n.fold, featurescores.folds = featurescores.folds,类型=类型)表summary="R valueblock"> <tr valign="top"> <TD>thresholds </ TD> <TD>矢量阈值,认为</ TD> </ TR> <tr valign="top"> <TD>n.threshold </ TD> <TD>的阈值</ TD> </ TR> <tr valign="top"> <TD >nonzero</ TD> <TD>功能,超过阈值的每个值</ TD> </ TR> <tr valign="top"> <TD> scor</ TD> <TD>全部CV值</ TD> </ TR> <tr valign="top"> <TD> scor.lower</ TD> <TD>完整简历成绩减去一个标准误差值</ TD> </ TR> <tr valign="top"> <TD> scor.upper </ TD> <TD>完整简历分数加一个标准误差分数</ TD> </ TR> <TR VALIGN =“顶部“> <TD> folds </ TD> <TD>指数CV倍数</ TD> </ TR> <tr valign="top"> <TD> n.fold </ TD> <TD>用于交叉验证</ TD> </ TR> <tr valign="top"> <TD>featurescores.folds </ TD> <TD>功能分数为每个倍数的褶皱</ TD> </ TR> <tr valign="top"> <TD>type </ TD> <TD>问题类型</ TD> </ TR> </ TABLE>
(作者)----------Author(s)----------
Yuping Zhang
实例----------Examples----------
x = list()
for(i in 1:2){
set.seed(i+123)
x[[i]] = matrix(rnorm(500*100), ncol=100)
}
y = sample(c(5:100), size=100, replace=TRUE)
censoring = sample(c(0,1), size=100, replace=TRUE)
data = list(x = x, y=y, censoring.status=censoring, genenames = as.character(paste("gene", c(1:500), sep="")), geneid = as.character(paste("gene", c(1:500), sep="")))
x = list()
for(i in 1:2){
set.seed(i+133)
x[[i]] = matrix(rnorm(500*100), ncol=100)
}
y = sample(c(5:100), size=100, replace=TRUE)
censoring = sample(c(0,1), size=100, replace=TRUE)
data.test = list(x = x, y=y, censoring.status=censoring, genenames = as.character(paste("gene", c(1:500), sep="")), geneid = as.character(paste("gene", c(1:500), sep="")))
fit = tspc.train(data, data.test, type="survival")
cv.obj = tspc.cv(fit$fit.obj, data, type="survival", n.fold=2)
转载请注明:出自 生物统计家园网(http://www.biostatistic.net)。
注:
注1:为了方便大家学习,本文档为生物统计家园网机器人LoveR翻译而成,仅供个人R语言学习参考使用,生物统计家园保留版权。
注2:由于是机器人自动翻译,难免有不准确之处,使用时仔细对照中、英文内容进行反复理解,可以帮助R语言的学习。
注3:如遇到不准确之处,请在本贴的后面进行回帖,我们会逐渐进行修订。
|