simMissing(simsem)
simMissing()所属R语言包:simsem
Construct a SimMissing object to create data with missingness and analyze missing data.
建设一个SimMissing的对象创建数据与missingness和分析缺失数据。
译者:生物统计家园网 机器人LoveR
描述----------Description----------
Function creates a SimMissing object that can be passed to simResult for creating and analyzing data with missingness.
函数创建一个SimMissing的对象,可以传递给simResult用于创建和分析与missingness的数据的。
用法----------Usage----------
simMissing(cov=0, pmMCAR=0, pmMAR=0, nforms=0, itemGroups=list(0), timePoints=1, twoMethod=0, prAttr=0, numImps=0, ignoreCols=0, threshold=0, covAsAux=TRUE, logical=new("NullMatrix"), ...)
参数----------Arguments----------
参数:cov
Column indices of any normally distributed covariates used in the data set.
任何正态分布的协变量的数据集的列索引。
参数:pmMCAR
Decimal percent of missingness to introduce completely at random on all variables.
十进制%的missingness介绍完全随机对所有的变量。
参数:pmMAR
Decimal percent of missingness to introduce using the listed covariates as predictors.
十进制%的missingness介绍上市的协变量的预测。
参数:nforms
The number of forms for planned missing data designs, not including the shared form.
计划丢失的数据设计的形式,但不包括共享的形式。
参数:itemGroups
List of lists of item groupings for planned missing data forms. Without this, items will be divided into groups sequentially (e.g. 1-3,4-6,7-9,10-12)
项目组计划丢失的数据形式的列表名单。没有这一点,项目将被分为组顺序(例如1-3,4-6,7-9,10-12)
参数:twoMethod
Vector of (percent missing, column index). Will put a given percent missing on that column in the matrix to simulate a two method planned missing data research design.
矢量(%丢失,列索引)。会放一个给定的百分比在该列中缺少的矩阵两种方法来模拟一个计划丢失数据的研究设计。
参数:prAttr
Probability (or vector of probabilities) of an entire case being removed due to attrition at a given time point. See imposeMissing for further details.
被删除的概率(或概率的向量)的整个壳体由于磨损在给定的时间点。见imposeMissing进一步的细节。
参数:timePoints
Number of timepoints items were measured over. For longitudinal data, planned missing designs will be implemented within each timepoint.
时间点项目的数量进行测量。纵向数据,将实施计划缺少的设计在每一个时间点。
参数:numImps
The number of imputations to be used when multiply imputing missing data. Setting numImps to 0 will use FIML to handle missing data.
的数量时要使用的乘法填充缺失数据的插补。处理缺失数据,将使用FIML将numImps设置为0。
参数:ignoreCols
The columns not imposed any missing values for any missing data patterns
列不施加任何缺失值的任何丢失的数据模式
参数:threshold
The threshold of covariates that divide between the area to impose missing and the area not to impose missing. The default threshold is the mean of the covariate.
阈值的协变量之间的鸿沟的区域征收人失踪,宅碱基的面积不得征收缺少的。预设的阈值协变量的平均值。
参数:covAsAux
If TRUE, the covariate listed in the object will be used as auxiliary variables when putting in the model object. If FALSE, the covariate will be included in the analysis.
如果TRUE,协变量中列出的对象将被用来作为辅助变量时,模型中的对象。如果FALSE,协将被包括在分析中。
参数:logical
A matrix of logical values (TRUE/FALSE). If a value in the dataset is corresponding to the TRUE in the logical matrix, the value will be missing.
矩阵的逻辑值(TRUE/FALSE“)。如果在数据集中的值是对应的TRUE的逻辑矩阵,该值将丢失。
参数:...
Additional arguments to be passed to amelia for imputation. Only used if numImps is greater than 0.
其他参数传递给amelia归集。仅用于numImps是大于0。
Details
详细信息----------Details----------
Without specifying any any arguments, no missingness will be introduced. Covariates are required to impose MAR missing. Imputations will be performed with Amelia
如果不指定任何参数,没有missingness将会推出。需要征收MAR缺失的协变量。插补将执行与阿米莉亚
值----------Value----------
A simMissing object to be used with SimResult.
一个simMissing对象使用与SimResult。
(作者)----------Author(s)----------
Alexander M. Schoemann (University of Kansas; <a href="mailto:schoemann@ku.edu">schoemann@ku.edu</a>)
Patrick Miller(University of Kansas; <a href="mailto:patr1ckm@ku.edu">patr1ckm@ku.edu</a>)
Sunthud Pornprasertmanit (University of Kansas; <a href="mailto:psunthud@ku.edu">psunthud@ku.edu</a>)
参见----------See Also----------
SimMissing for the alternative way to save missing data feature for using in the simResult function.
SimMissing的另一种方式,以节省使用simResult功能的缺失数据的功能。
runMI for imputing missing data by multiple imputation and analyze the imputed data.
runMI填充缺失数据的多重插补和分析估算数据。
实例----------Examples----------
#Example of imposing 10% MCAR missing in all variables with no imputations (FIML method)[没有诋毁征收10%的MCAR中缺少的所有变量(例FIML方法)]
Missing <- simMissing(pmMCAR=0.1)
summary(Missing)
loading <- matrix(0, 6, 1)
loading[1:6, 1] <- NA
LX <- simMatrix(loading, 0.7)
RPH <- symMatrix(diag(1))
RTD <- symMatrix(diag(6))
CFA.Model <- simSetCFA(LY = LX, RPS = RPH, RTE = RTD)
SimData <- simData(CFA.Model, 500)
SimModel <- simModel(CFA.Model)
#Create data[创建数据]
dat <- run(SimData)
#Impose missing[征收失踪]
dat <- run(Missing, dat)
#Analyze data[分析数据;]
out <- run(SimModel, dat)
summary(out)
#Example to create simMissing object for 3 forms design at 3 timepoints with 10 imputations[举个例子来创建对象为3种形式设计simMissing 3的时间点,10指摘]
Missing <- simMissing(nforms=3, timePoints=3, numImps=10)
转载请注明:出自 生物统计家园网(http://www.biostatistic.net)。
注:
注1:为了方便大家学习,本文档为生物统计家园网机器人LoveR翻译而成,仅供个人R语言学习参考使用,生物统计家园保留版权。
注2:由于是机器人自动翻译,难免有不准确之处,使用时仔细对照中、英文内容进行反复理解,可以帮助R语言的学习。
注3:如遇到不准确之处,请在本贴的后面进行回帖,我们会逐渐进行修订。
|