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

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

[复制链接]
发表于 2012-9-30 11:01:45 | 显示全部楼层 |阅读模式
rperm(sna)
rperm()所属R语言包:sna

                                         Draw a Random Permutation Vector with Exchangeability Constraints
                                         绘制一个随机置换向量的互换性约束

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

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

Draws a random permutation on 1:length(exchange.list) such that no two elements whose corresponding exchange.list values are different are interchanged.
绘制一个随机置换1:length(exchange.list)如exchange.list的值是不同的,其相应的没有两个元素互换。


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


rperm(exchange.list)



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

参数:exchange.list
A vector such that the permutation vector may exchange the ith and jth positions iff exchange.list[i]==exchange.list[j]
这样一个向量,置换矢量可以交换第i个和第j个位置,当且仅当exchange.list[i]==exchange.list[j]


Details

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

rperm draws random permutation vectors given the constraints of exchangeability described above.  Thus, rperm(c(0,0,0,0)) returns a random permutation of four elements in which all exchanges are allowed, while rperm(c(1,1,"a","a") (or similar) returns a random permutation of four elements in which only the first/second and third/fourth elements may be exchanged.  This turns out to be quite useful for searching permutation spaces with exchangeability constraints (e.g., for structural distance estimation).
rperm绘制给定的约束上述的可交换性的随机排列向量。因此,rperm(c(0,0,0,0))返回一个随机排列的四个要素中,允许所有交易所,而rperm(c(1,1,"a","a")(或类似)返回一个随机排列的四个要素中,只有第一/第二和第三/第四个元素可以交换。这将是非常有用的搜索排列空间的可交换性约束(例如,结构距离估计)。


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

A random permutation vector satisfying the given constraints
随机置换矢量满足给定的约束条件


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


Carter T. Butts <a href="mailto:buttsc@uci.edu">buttsc@uci.edu</a>



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

rmperm
rmperm


实例----------Examples----------


rperm(c(0,0,0,0))  #All elements may be exchanged[可以交换的所有元素]
rperm(c(0,0,0,1))  #Fix the fourth element[修正的第四个元素]
rperm(c(0,0,1,1))  #Allow {1,2} and {3,4} to be swapped[允许{1,2},{3,4}被换]
rperm(c("a",4,"x",2))  #Fix all elements (the identity permutation)[修复所有元素(身份置换)]

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


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

使用道具 举报

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

本版积分规则

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

GMT+8, 2025-6-8 08:03 , Processed in 0.028886 second(s), 16 queries .

Powered by Discuz! X3.5

© 2001-2024 Discuz! Team.

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