找回密码
 注册
查看: 628|回复: 0

R语言 RMC包 sim.chain()函数中文帮助文档(中英文对照)

[复制链接]
发表于 2012-9-26 23:56:52 | 显示全部楼层 |阅读模式
sim.chain(RMC)
sim.chain()所属R语言包:RMC

                                        Simulate Markov chain data from a Markov model.
                                         模拟马尔可夫链马尔可夫模型的数据。

                                         译者:生物统计家园网 机器人LoveR

描述----------Description----------

Simulate chained data from a simple reversible Markov model (see Foster et al 2009 for details). Simulates stationary and non-stationary data, the later is formed by defining the transition matrix as a function of covariates.
模拟链接数据从一个简单的的可逆马尔可夫模型(有关详细信息,请参阅2009年Foster等)。模拟静止和非平稳的数据,购买通过定义作为协变量的函数的过渡矩阵形成。


用法----------Usage----------


sim.chain( n.chains = 5, n.obs = rep( 100, n.chains), n.cats = 3, n.covars = 1, beta = NULL, gamma = NULL, X = NULL)



参数----------Arguments----------

参数: n.chains
scalar specifying the number of chains to simulate. The default value is 5.
标指定链的数量来模拟。默认值是5。


参数: n.obs
vector of length n.chains. Indicates the number of observations per chain. Default is rep( 100, n.chains) for 5 chains of 100 observations.
向量的长度n.chains。每个链的观测数。默认值是代表(100,n.chains)5链的100个观测。


参数: n.cats
scalar specifying the number of categories in the chain. Default is 3 states.
标链中的指定类别的数量。默认值是3种状态。


参数: n.covars
The number of covariates that affect the transition matrix. The constant must be considered to be one of these covariates. Default is n.covars=1 for constant term only (stationary chain).
的过渡矩阵的协变量的影响。该常数必须被认为是这些相关变量之一。默认值是n.covars = 1的常数项(固定链)。


参数: beta
elements of the matrix of coefficients for the probability of moving into each state, used to partially define the transition matrices (also need gamma). These values are transformed via the additive logistic transform. The dimension of the beta matrix must be nrow=n.covars and ncol=n.cats with rows indexing the covariates and columns indexing the transformed probabilities (transformed from a simplex with the additive logistic transform). The first column of this matrix must be zero, reflecting that the last category's transition probability is constrained.
元素的矩阵的系数为迁入的每个状态,用来部分地限定过渡矩阵(也需要γ)的概率。这些值是通过添加剂MF变换转化。的β矩阵的尺寸必须是NROW = n.covars和ncol = n.cats索引变换概率(从一个单一的与添加剂MF变换转化)的协变量和列的索引与行的。此矩阵的第一列必须是零,反射,最后一类的过渡概率被约束。


参数: gamma
elements of the matrix of coefficients for the probability of moving from any particular state, used to partially define the transition matrices (also need beta). These parameters are transformed using the logistic transform. The dimension of the gamma matrix must be nrow=n.covars and ncol=n.cats with rows indexing covariates and columns indexing states.
从任何特定的状态,用来部分地限定的过渡矩阵(也需要测试)的移动的概率的系数矩阵的元素。这些参数被变换使用MF变换。 γ基体的尺寸必须是NROW = n.covars和ncol = n.cats与行索引的协变量和列索引状态。


参数: X
The design matrix for the covariates. If NULL (the default) then the design matrix is filled with a constant and random (normal) variables. The design matrix must be numeric with all factors suitably converted into dummy variables and so on.
矩阵的协变量的设计。如果为NULL(默认值),然后设计矩阵充满了一个常数,随机变量(正常)。适当地转换成虚拟变量等各方面的因素,设计矩阵必须是数字。


Details

详细信息----------Details----------

The observed chained categorical model is defined according to Foster et al (2009). The Markov process is assumed to be parameterised by two vectors, phi and pi. The phi parameters indicate the probability of moving from each state and the pi probabilities prescribe the probability of moving to each state given that a move will occur. This process is reversible if the parameters do not change within a chain. The probabilities are allowed to vary within a chain by specifying these two vectors of probabilities as functions of covariates (possibly index number).
根据Foster等人(2009)所观察到的链接分类模型定义。马尔可夫过程被假定为两个向量,φ和PI参数化。披参数的概率从每个国家和圆周率的概率规定移动到每个国家,此举将发生的概率。这个过程是可逆的,如果参数不改变,内链。允许内改变链,通过指定这两个向量的协变量的函数(可能是索引号)的概率的概率。


值----------Value----------

The function returns a matrix with columns for the chain identification (values from 1 to n.chains), the simulated chained data, and a column for each of the scaled X matrix.
该函数返回一个矩阵列的链的识别(值从1到n.chains),模拟链状数据,和一个为每个缩放后的X矩阵的列。


(作者)----------Author(s)----------


Scott D. Foster



参考文献----------References----------

转载请注明:出自 生物统计家园网(http://www.biostatistic.net)。


注:
注1:为了方便大家学习,本文档为生物统计家园网机器人LoveR翻译而成,仅供个人R语言学习参考使用,生物统计家园保留版权。
注2:由于是机器人自动翻译,难免有不准确之处,使用时仔细对照中、英文内容进行反复理解,可以帮助R语言的学习。
注3:如遇到不准确之处,请在本贴的后面进行回帖,我们会逐渐进行修订。
回复

使用道具 举报

您需要登录后才可以回帖 登录 | 注册

本版积分规则

手机版|小黑屋|生物统计家园 网站价格

GMT+8, 2024-11-23 23:50 , Processed in 0.023460 second(s), 16 queries .

Powered by Discuz! X3.5

© 2001-2024 Discuz! Team.

快速回复 返回顶部 返回列表