Description Usage Arguments Value Author(s) See Also Examples
Get the function object used for generating inserts.
1 2 | ## S3 method for class 'GeneralInsertor'
getGenerateBy(this, ...)
|
this |
A GeneralInsertor object. |
... |
Not used. |
A function object.
Botond Sipos, Gregory Jordan
For more information see GeneralInsertor
.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 | # create a GeneralInsertor object
i<-GeneralInsertor(
rate=0.5,
propose.by=function(process){sample(c(5:10),1)}, # inserts between 5 and 10
template.seq=NucleotideSequence(string="AAAAAAA")
)
# save insert generator
old.gen<-getGenerateBy(i)
# set a new insert generator
i$generateBy<-function(
process,
length,
target.seq,
event.pos,
insert.pos
){
return(NucleotideSequence(string="AATTGGCC"))
}
# get the generator function
i$generateBy
# generate insert
generateInsert(i)
# restore old generator
i$generateBy<-old.gen
# generate insert
generateInsert(i)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.