Σi=02 Σj=01(exp(xi+xj)), i>j if (i>0 and j>0) I want to write this summation which has a condition on numerator(j<i)i>0 and j>0I tried on this code sum(sapply(0:2, function(i){sum(sapply(0:1, function(j){if (i>0&j>0){i>j}{exp(x[i]+x[j])}))}))But it didn't work Any help please [[alternative HTML version deleted]]
______________________________________________ R-help@r-project.org mailing list -- To UNSUBSCRIBE and more, see https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting-guide.html and provide commented, minimal, self-contained, reproducible code.