search for: wrowsum

Displaying 2 results from an estimated 2 matches for "wrowsum".

Did you mean: rowsum
2013 Feb 06
1
weighing proportion of rowSums in dataframe
...     15 6 x06      1           NA     NA       6 #and then calculate a rowsum, were each column is weighed by its associated factor in the vector "w", i.e. all entries in column df$a should be weighed by the factor 10.5, df$b by 9 and df$c by 12.8 and then summed up to a weighed rowsum (wrowsum=10.5*0.33+9*0.66). Any suggestions how to achieve this in a simple way with dataframes that have 9000 rows and 44 columns (so I cannot do this row by row) - sorry, if this is to easy a question. Thank you very much in advance! Best wishes Alain [[alternative HTML version deleted]]
2013 Feb 06
0
weighing pro​portion of rowSums i​n dataframe
...> > 6 x06 1 NA NA 6 > > > > #and then calculate a rowsum, were each column is weighed by its associated factor in the vector "w", i.e. all entries in column df$a should be weighed by the factor 10.5, df$b by 9 and df$c by 12.8 and then summed up to a weighed rowsum (wrowsum=10.5*0.33+9*0.66). > > > > Any suggestions how to achieve this in a simple way with dataframes that have 9000 rows and 44 columns (so I cannot do this row by row) - sorry, if this is to easy a question. > > > > Thank you very much in advance! > > > > Best w...