From mboxrd@z Thu Jan 1 00:00:00 1970 From: Alan Schmitt Subject: Re: How to do a sum of products in a table? Date: Fri, 14 Jun 2013 18:49:36 +0200 Message-ID: References: <87mwqs7mjv.fsf@pank.home> Mime-Version: 1.0 Content-Type: text/plain Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:37694) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UnXBz-0001Qv-CW for emacs-orgmode@gnu.org; Fri, 14 Jun 2013 12:49:40 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1UnXBx-0005QJ-KF for emacs-orgmode@gnu.org; Fri, 14 Jun 2013 12:49:39 -0400 Received: from mail2-relais-roc.national.inria.fr ([192.134.164.83]:12526) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UnXBx-0005Q5-D7 for emacs-orgmode@gnu.org; Fri, 14 Jun 2013 12:49:37 -0400 In-reply-to: <87mwqs7mjv.fsf@pank.home> List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org Sender: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org To: Rasmus Cc: emacs-orgmode@gnu.org Hi Rasmus, Rasmus writes: > Sure, but please provide an example. Yes, I should have done that. Here is the beginning of the grading (I removed many columns which are identical). | Name | Grade | Question 1 | Question 2 | Question 3 | | Coeff | 6 | 1 | 3 | 2 | |-------+-------+------------+------------+------------| | Foo | | 1/2 | 1 | 1/4 | | Bar | | 1 | 1 | 0 | #+TBLFM: @2$2=vsum($3..$>) I would like the grade of Foo to be 10 * (1/2 * 1 + 1 * 3 + 1/4 * 2)/6 and Bar to be 10 * (1 * 1 + 1 * 3 + 0 * 2)/6 > E.g. is each student a column? Each student is a row, an each question is a column. > A more advance example is given in the manual: > > http://orgmode.org/org.html#Advanced-features Thanks, but I does not seem to do what I want. I prefer to keep the coefficient in the column with the question name so that I can easily know what it refers to when I adjust it. Thanks again, Alan