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

R语言 ChIPsim包 makeFeatures()函数中文帮助文档(中英文对照)

[复制链接]
发表于 2012-2-25 14:56:36 | 显示全部楼层 |阅读模式
makeFeatures(ChIPsim)
makeFeatures()所属R语言包:ChIPsim

                                         Generating a list of genomic features
                                         生成的基因组功能列表

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

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

This function generates a list of genomic features for a single chromosome based on a Markov model.
这个函数生成一个基于马尔可夫模型的一个单一的染色体基因组功能的列表。


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


makeFeatures(generator = defaultGenerator(),
        transition = defaultTransition(), init = defaultInit(),
        start = 1000, length, control = list(),
        globals = list(minDist = 175), lastFeat = defaultLastFeat(),
        experimentType = "NucleosomePosition",
        truncate = FALSE, maxTries = 10, force=FALSE)



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

参数:generator
A named list providing functions to generate the parameters associated with each type of feature.  The name of each element in the list is the name of the state the function should be associated with.   
命名的列表提供的功能来生成与每个类型的功能相关的参数。列表中的每个元素的名称是功能应与国家的名称。


参数:transition
Named list of transition probabilities. Each element is a (named) numeric vector giving the transition probabilities for the state indicated by the element's name, i.e., each element of the list is a row of the transition probability matrix but zero probabilities can be omitted.  
命名的转移概率的列表。每个元素(命名)给状态转移概率的数值向量元素的名称,即列表中的每个元素是一排的转移概率矩阵,但零概率可以省略。


参数:init
Named numeric vector of initial state probabilities. The names have to correspond to state names of the model. Zero probabilities may be omitted.  
名为数字矢量的初始状态概率。该名称必须对应到模型的国家名称。零概率可以被省略。


参数:start
Numeric value indicating the position at which the first feature should be placed.  
数字值,该值指示的位置应放在第一功能。


参数:length
Maximum length of DNA that should be covered with features.   
DNA的最大长度应与功能覆盖。


参数:control
Named list with additional arguments to generator functions (one list per generator).  Again the names should be the same as the state names.  
命名额外的参数列表发生器功能(每一个发电机名单)。再次,名称应该为国家名称相同。


参数:globals
List of global arguments to be passed to all generator functions.  
发生器的所有功能将被传递给全球的参数列表。


参数:lastFeat
Named logical vector indicating for each feature type whether it can be the last feature.  
命名逻辑向量表示每个要素类型,它是否能成为最后的功能。


参数:experimentType
Type of experiment the simulated features belong to. This is used as the class of the return value.  
实验模拟功能属于类型。这是用来作为返回值的类。


参数:truncate
Logical value indicating whether the final feature should be truncated to ensure that total length does not exceed length (if FALSE, a feature that would be truncated is removed instead).  
逻辑值,该值指示是否应该被截断,以确保,总长度不超过length如果FALSE,一个将被截断的功能删除,而不是最终的功能。


参数:maxTries
Maximum number of attempts made to generate a valid sequence of features. If no valid sequence is  generated during the first maxTries attempts the function will fail either silently  (returning an empty sequence) or raise an error, depending on the value of force.  
最大尝试次数生成一个有效的序列特征。如果没有有效的序列过程中生成第一maxTries尝试函数将失败,要么默默(返回一个空序列)或抛出一个错误,在取决于force的价值。


参数:force
Logical indicating whether the function should be forced to return a feature sequence, even if no valid sequence was found. If this is TRUE an empty sequence will be returned in that case  otherwise an error is raised.  
逻辑指示是否应强制函数返回一个特征序列,发现即使没有有效的序列。如果这是TRUE在这种情况下将返回一个空序列,否则会引发错误。


Details

详情----------Details----------

This function will generate features from any first order Markov model specified by init, transition  and generator. If force is FALSE the returned feature sequence is guaranteed to contain at least one feature and end in a state that is indicated as possible end state in lastFeat. Note that the states for which lastFeat is TRUE are not end states in the sense that the chain is terminated once the state is  entered or that the chain remains in the state once it is first entered. Instead this is a mechanism to ensure that  some states cannot be the last in the sequence.
此功能会产生init,transition和generator指定从任何一阶马尔可夫模型的特点。如果force是FALSE返回的功能顺序保证包含至少一个功能和状态的结束,在lastFeat可能最终状态表示。注意:美国lastFeat是TRUE没有结束在这个意义上,链终止状态,一旦进入状态或链中的状态还有一次是第一次进入。相反,这是一种机制,以确保一些国家不能是序列中的最后。

Due to the constrains on the total length  of DNA covered by features as well as the possible constraint on the final feature of the sequence it is possible to specify models that cannot produce a legal sequence. In other cases it may be possible but unlikely to produce a feature sequence that satisfies both constraints. A serious attempt is made to  satisfy both requirement, generating a new feature sequence or truncating an existing one if necessary. To ensure that this terminates eventually the number of attempts to generate a valid sequence are limited to maxTries.
由于特征以及可能的约束,它可以指定模型不能产生一个合法的序列对序列的最后一个功能所涵盖的DNA总长度的限制。在其他情况下,它可能是可能的,但不太可能产生一个特征序列,满足这两个约束。一个严重的尝试,以满足双方的要求,产生一个新的功能序列或截断一个现有的,如果必要的。为了确保这个终止最终尝试生成一个有效的序列的数量是有限的maxTries。

In some cases it may be desirable to carry out some post-processing of the feature sequence to ensure that parameters of neighbouring features are compatible in some sense. For the default nucleosome positioning simulation the function reconcileFeatures provides this functionality and placeFeatures is an interface to makeFeatures that utilises reconcileFeatures.
在某些情况下可能需要进行一些功能序列的后处理,以确保周边功能参数在某种意义上兼容。为默认的核小体定位的仿真功能reconcileFeatures提供这一功能和placeFeatures是一个接口makeFeatures利用reconcileFeatures。


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

A list of features (with class determined by experimentType).  Each feature is represented by a list of parameters and has a class with the same name as the state that generated the feature. In addition all features are of class SimulatedFeature.
一个功能列表(带班由experimentType决心)。每个功能是代表一个参数列表,并有一类状态,产生的功能相同的名称。此外,所有的功能类SimulatedFeature。


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



Peter Humburg




参见----------See Also----------

Functions to generate default values for some of the arguments: defaultGenerator, defaultInit, defaultTransition, defaultLastFeat.
函数产生的一些参数的默认值:defaultGenerator,defaultInit,defaultTransition,defaultLastFeat。

Use feat2dens to convert a feature sequence into feature densities.
使用feat2dens功能密度的功能序列转换成。

placeFeatures is an interface to makeFeature for nucleosome positioning.
placeFeaturesmakeFeature是核小体定位的接口。


举例----------Examples----------


set.seed(1)
## generate a (relatively short) sequence of nucleosome features[#产生的核小体的功能(比较短)序列。]
features <- makeFeatures(length=1e6)

## check the total length of the features[#查询功能的总长度]
sum(sapply(features, "[[", "length")) ## 995020 [#995020]

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


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

使用道具 举报

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

本版积分规则

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

GMT+8, 2025-5-14 15:07 , Processed in 0.039301 second(s), 16 queries .

Powered by Discuz! X3.5

© 2001-2024 Discuz! Team.

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