Hello:
I would like to sum every x columns of a dataframe for each row. For instance,
if x is 10, then for dataframe df, this function will sum the first ten elements
together and then the next ten:
sapply(list(colnames(df)[1:10], colnames(df)[11:20]),function(x)apply( df[,x],
1, sum))
If the
Hello:
I am using R 2.7.2 for Windows. I have been using chron() to convert from
Julian to calendar dates. How do I ignore leap years? Thanks.
Cheers,
Michael
--
Michael I. Westphal, PhD
Africa Region Water Resource
2 matches
Mail list logo