title: Row product of matrix and column sum of matrix
body: <p>I have a matrix of size TxR and I am looking for a command to do the product of the rows (returning an 1 x R vector of the products). After that I want to sum over the columns, i.e. sum the R terms. </p>
  
  <p>In Matlab this would be done something like this sum(prod(A,1),2), but I don't know the code for this in R.</p>
  
  <p>I hope it make sense.</p>
  
  <p>Thanks</p>