Skip to content
Prev 77929 / 398503 Next

dynamic lists (data frames?)

Tom
Hmm my bad,
Thanks for your replies but I think my example was a little to simple
the actual code I'm using is:


f_haardisolve<-function(v_dataset){
    #pad data to make length a power of 2
    v_dataset<-f_paddata(v_dataset)

    l_cooef<-list() #holder for cooefficents
    i_count<-1      #identity counter

    while(length(v_dataset)>0){
        #seperate odd and even points
        v_dataset<-f_splitpoints(v_dataset)

        v_dataset<-f_haarpredict(v_dataset)
        v_dataset<-f_haaruplift(v_dataset)
        
        str_idx<-paste('c',i_count,sep='')
	l_cooef
$str_idx<-v_dataset[c((length(v_dataset)/2)+1:(length(v_dataset)/2))]
#should be no wrap on the previous line 

       v_dataset<-v_dataset[c(1:length(v_dataset)/2)]

        i_count<-i_count+1
    }
    l_cooef
}

In this particular case I could probably calculate the number of
iterations and use l_cooef<-names() but more is there a more generic
method for adding another column of data?
On Tue, 2005-27-09 at 10:39 -0400, tom wright wrote: