[Seqinr-commits] r1738 - pkg/R

noreply at r-forge.r-project.org noreply at r-forge.r-project.org
Sun Mar 7 12:13:18 CET 2010


Author: lobry
Date: 2010-03-07 12:13:18 +0100 (Sun, 07 Mar 2010)
New Revision: 1738

Modified:
   pkg/R/count.R
Log:
word -> wordsize

Modified: pkg/R/count.R
===================================================================
--- pkg/R/count.R	2010-03-07 11:12:45 UTC (rev 1737)
+++ pkg/R/count.R	2010-03-07 11:13:18 UTC (rev 1738)
@@ -14,15 +14,15 @@
 #
 # oligos.levels contains all possible oligomers for a given alphabet:
 #
-  oligos.levels <- levels(as.factor(words(word, alphabet = alphabet)))
+  oligos.levels <- levels(as.factor(words(wordsize, alphabet = alphabet)))
 #
 # For n-mers with n >= 2 we paste the following characters in the
 # sequence to build the observed set of all oligomers. Some NA are
 # generated at the end of the sequence and discarded when counting
 # them.
 #
-  if (word >= 2){
-    for(i in 2:word){
+  if (wordsize >= 2){
+    for(i in 2:wordsize){
       oligos <- paste(oligos, seq[istarts + i - 1], sep = "")
     }
   }



More information about the Seqinr-commits mailing list