Displaying 1 result from an estimated 1 matches for "auto_avg".
Did you mean:
auth_alg
2009 Dec 22
2
Nested For loops
...tab1<-c()
tab2<-c()
ps_value <- seq(0,(floor(entry/2)),1)
for(k in 0:(floor(entry/2))){
for (i in 1:(entry-k)) {
mult<-(data_value[i] - data_value_mean) * (data_value [i+k] - data_value_mean)
tab1 <- c(tab1,mult)
}
auto_avg<-mean(tab1)
tab1<-c()
auto_corr<-auto_avg/deno
tab2<-c(tab2,auto_corr)
}
table_value <- cbind (ps_value, tab2)
colnames(table_value) <- c("#ps", "acf")
outfile<-unlist(strsplit(infile, split="."...