ResampleExactSpawML(spacom)
ResampleExactSpawML()所属R语言包:spacom
Spatially weighted multilevel analysis with stratified resampling for exact context data
空间权重的多级分层重采样分析,准确的环境数据
译者:生物统计家园网 机器人LoveR
描述----------Description----------
Performs multilevel analysis with spatially weighted context data based on precise contextual measures. Provides robust point estimates and adjusted standard errors, obtained by stratified bootstrap resampling.
空间加权的基础精确的上下文措施的上下文数据进行多层次分析。提供强大的点估计和调整后的标准误差,分层引导重采样得到的。
用法----------Usage----------
ResampleExactSpawML(individual.level.data,
contextual.names,
context.id,
formula,
precise.data,
contextual.weight.matrices = NULL,
confidence.intervals = c(0.95),
nb.resamples = 1000,
individual.sample.seed = NULL)
参数----------Arguments----------
参数:individual.level.data
A data.frame containing the individual level data. The data must be numeric (logical, integer, or plain numeric). There may not be any missing values, NaNs, NULLs or NAs.
Adata.frame个人层面上的数据。数据必须是数字(logical,integer,或纯numeric)。可能没有任何遗漏值,NaN,NULLs或NA的。
参数:contextual.names
A list of names of contextual variables to be weighted.
Alist进行加权的上下文变量的名称。
参数:context.id
The name of the context ID variable.
作为上下文ID的变量的名称。
参数:formula
Formula description of the model.
公式描述的模式。
参数:precise.data
A data.frame containing the precise contextual data. May be NULL, but may not contain any missing values, like NaNs, NULLs or NAs. By default set to NULL, except for ResampleExactSpawML which requires precise data to be specified.
Adata.frame包含精确的上下文数据。可能是NULL,但可能不包含任何遗漏值,如NaN,NULL或NA的。默认设置为NULL,除了ResampleExactSpawML这需要精确的数据来指定。
参数:contextual.weight.matrices
A list of weights to be applied to each variable specified in contextual.names. A weight may be a weights matrix as, for instance computed by WeightMatrix, or NULL, in which case the corresponding contextual variable is not weighted. If only one weight is defined (instead of a list) it is applied to all contextual variables. Defaults to NULL, which means that none of contextual indicators are weighted.
Alist权重的被应用到每个指定的变量中contextual.names。作为,例如计算WeightMatrix,或NULL,在这种情况下,相应的上下文变量的权重,权重可能是一个权重矩阵。如果只有一个重量被定义(而不是一个列表),它被应用到所有的上下文变量。默认值,以NULL,这意味着没有上下文指标的权重。
参数:confidence.intervals
vector of confidence intervals. Defaults to c(.95) which corresponds to 95 %.
vector的置信区间。默认为c(.95)对应于95%。
参数:nb.resamples
number of resamples to be evaluated. By default set to 1000
重新采样数进行评估。默认情况下设置为1000
参数:individual.sample.seed
Seed used to generate the random sampling of the individual data Is one of three things <ol> NULL, in which case whatever the current random seed is is used
种子用于生成的个别数据的随机抽样是<OL>NULL,在这种情况下,不管当前的随机种子使用的三件事情之一
an integer, which will be used to set the random seed. This allows reproducible random samples
的integer,将用于设置随机种子。这允许重复的随机样本
a saved .Random.seed which allows reproducible random samples as well. The reason why both 2 and 3 are present is because .Random.seed can be saved a posteriori. </ol> Defaults to NULL.
已保存的.Random.seed可重现的随机样本,以及。为什么2和3都存在的原因是因为.Random.seed可以保存后验。 </ OL>默认值到NULL。
(作者)----------Author(s)----------
Till Junge, Sandra Penic, Guy Elcheroth
实例----------Examples----------
# Spatially weighted multilevel analysis, with resampled individual[空间加权的多层次分析,重采样个人]
# level indicators and precise contextual indicator. Predicting collective[一级指标和精确的背景指标。预测集体]
#guilt acceptance.[内疚验收。]
# load individual level data, remove collective guilt assignment for the[加载个体层面的数据,除去集体罪责分配]
#data frame, and remove NA's [数据框,并删除NA]
data(traces_ind)
traces_ind <- traces_ind[,-7]
traces_ind <- na.exclude(traces_ind)
# load precise contextual indicator[加载精确的背景指标]
data(homog_census)
# load distance matrix and create weights[加载距离矩阵和权重]
data(d_geo)
geow_100 <- WeightMatrix(d_geo, bandwidth=100)
# perform ResampleExactSpawML[执行ResampleExactSpawML]
acc_homog00_100 <- ResampleExactSpawML(individual.level.data=traces_ind,
contextual.names="Homog_00", context.id="area", formula=cg_acc ~
victim_d + comb_d + male + age_1990 + high_school + higher_edu +
(1|area), precise.data=homog_census,
contextual.weight.matrices=geow_100, nb.resamples=10)
转载请注明:出自 生物统计家园网(http://www.biostatistic.net)。
注:
注1:为了方便大家学习,本文档为生物统计家园网机器人LoveR翻译而成,仅供个人R语言学习参考使用,生物统计家园保留版权。
注2:由于是机器人自动翻译,难免有不准确之处,使用时仔细对照中、英文内容进行反复理解,可以帮助R语言的学习。
注3:如遇到不准确之处,请在本贴的后面进行回帖,我们会逐渐进行修订。
|