Displaying 1 result from an estimated 1 matches for "dl_d".
Did you mean:
dl_
2009 Jun 02
2
What do you think about my function?
...d2=d2,dd3=d3,dd4=d4)
for (i in 1:length(n1)){
wekt_n = ndf[i,]
wekt_d = ddf[i,]
wekt_n_ok = wekt_n[!is.na(wekt_n)]
wekt_n_ok = as.numeric(wekt_n_ok)
wekt_d_ok = wekt_d[!is.na(wekt_d)]
wekt_d_ok = as.numeric(wekt_d_ok)
dl_n = length(wekt_n_ok)
dl_d = length(wekt_d_ok)
if (skl[i] %in% NA){ wynik[i]=NA}
else {wynik[i] =
sum(((1*wekt_n_ok)+(3*wekt_n_ok))/((1*dl_n)+(3*dl_d)))}
}
return (wynik)
}
### Call function ###
dzieci$zywnosc <- zywnoscCalosc(dzieci$zywnosc, dzieci$sklepik,
dzieci$sklslodycze, dzieci$sklnapojegazow...