xscat(Biostrings)
xscat()所属R语言包:Biostrings
Concatenate sequences contained in XString, XStringSet
CONCATENATE序列包含在XString,XStringSet
译者:生物统计家园网 机器人LoveR
描述----------Description----------
This function mimics the semantic of paste(..., sep="") but accepts XString, XStringSet or XStringViews arguments and returns an XString or XStringSet object.
此功能模仿paste(..., sep="")的的语义,但接受XString,XStringSet或XStringViews参数,并返回一个XString或XStringSet对象。
用法----------Usage----------
xscat(...)
参数----------Arguments----------
参数:...
One or more character vectors (with no NAs), XString, XStringSet or XStringViews objects.
一个或多个特征向量(不带NAS),XString,XStringSet或XStringViews的对象。
值----------Value----------
An XString object if all the arguments are either XString objects or character strings. An XStringSet object otherwise.
如果所有的论据是XString对象或字符串XString对象。另有一个XStringSet对象。
作者(S)----------Author(s)----------
H. Pages
参见----------See Also----------
XString-class, XStringSet-class, XStringViews-class, paste
一流的XString,XStringSet类,级XStringViews,paste
举例----------Examples----------
## Return a BString object:[#返回BString的对象:]
xscat(BString("abc"), BString("EF"))
xscat(BString("abc"), "EF")
xscat("abc", "EF")
## Return a BStringSet object:[#返回BStringSet的对象:]
xscat(BStringSet("abc"), "EF")
## Return a DNAStringSet object:[#返回DNAStringSet的对象:]
xscat(c("t", "a"), DNAString("N"))
## Arguments are recycled to the length of the longest argument:[#参数被回收到的长度最长的参数:]
xscat("x", LETTERS, c("3", "44", "555"))
## Concatenating big XStringSet objects:[#连接大XStringSet对象:]
library(drosophila2probe)
probes <- DNAStringSet(drosophila2probe)
mm <- complement(narrow(probes, start=13, end=13))
left <- narrow(probes, end=12)
right <- narrow(probes, start=14)
xscat(left, mm, right)
## Collapsing an XStringSet (or XStringViews) object with a small[#倍数与一个小XStringSet(或XStringViews)对象]
## number of elements:[#号元素:]
probes1000 <- as.list(probes[1:1000])
y1 <- do.call(xscat, probes1000)
y2 <- do.call(c, probes1000) # slightly faster than the above[除上述稍快]
y1 == y2 # TRUE[真]
## Note that this method won't be efficient when the number of[#注意,此方法将不会是有效的,当数]
## elements to collapse is big (> 10000) so we need to provide a[#元素的崩溃,所以我们需要提供一个大(> 10000)]
## collapse() (or xscollapse()) function in Biostrings that will[在Biostrings崩溃()(或xscollapse())函数将]
## be efficient at doing this. Please complain on the Bioconductor[#在这样做是有效的。请Bioconductor在抱怨]
## mailing list (http://bioconductor.org/docs/mailList.html) if you[#邮件列表(http://bioconductor.org/docs/mailList.html)如果你]
## need this.[#需要。]
转载请注明:出自 生物统计家园网(http://www.biostatistic.net)。
注:
注1:为了方便大家学习,本文档为生物统计家园网机器人LoveR翻译而成,仅供个人R语言学习参考使用,生物统计家园保留版权。
注2:由于是机器人自动翻译,难免有不准确之处,使用时仔细对照中、英文内容进行反复理解,可以帮助R语言的学习。
注3:如遇到不准确之处,请在本贴的后面进行回帖,我们会逐渐进行修订。
|