[adegenet-commits] r302 - pkg/R

noreply at r-forge.r-project.org noreply at r-forge.r-project.org
Thu Apr 30 20:44:44 CEST 2009


Author: jombart
Date: 2009-04-30 20:44:44 +0200 (Thu, 30 Apr 2009)
New Revision: 302

Modified:
   pkg/R/seqTrack.R
Log:
---


Modified: pkg/R/seqTrack.R
===================================================================
--- pkg/R/seqTrack.R	2009-04-30 15:57:14 UTC (rev 301)
+++ pkg/R/seqTrack.R	2009-04-30 18:44:44 UTC (rev 302)
@@ -78,11 +78,34 @@
     }
 
 
+    ## expand one path
+    expandOnePath <- function(onePath){ # onePath has a single path (a vector)
+        newPoints <- findAncestors(onePath[length(onePath)]) # get new points
+        if(is.null(newPoints)) return(onePath)
+        res <- lapply(1:length(newPoints), function(i) c(onePath, newPoints)) # duplicate path and add new pts
+        return(res)
+    }
+
+
+    ## check if CURRENTPATH should stop
+    checkEndCurrentPath <- function(){
+        temp <- sapply(CURRENTPATH, function(e) e[length(e)])
+        if(all(seq.dates>))
+
+    }
+
+
+
     ## FIND ONE PATH ##
     findPath <- function(id){
         temp <- findExistingPath(id) # search for an already existing path
         if(!is.null(temp)) return(temp)
 
+        ## WHILE LOOP ##
+        while(!is.null(currentPoint)){
+            checkExist <-
+            if()
+        }
 
         INPATH.up() # update id with known paths
         return(res)



More information about the adegenet-commits mailing list