Bookmark and Share

Notice: On April 23, 2014, Statalist moved from an email list to a forum, based at

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: st: need to sum several variables in a row

From   Richard Goldstein <>
Subject   Re: st: need to sum several variables in a row
Date   Tue, 17 Dec 2013 08:29:46 -0500

you are asked, in the FAQ for this list, to tell us exactly what you
typed; without knowing that we can only guess; you do want the egen
function "rowtotal"; see -h egen-


On 12/17/13, 8:18 AM, Raffaele Palladino wrote:
> Dear statalist, Im dealing with a problem that will be very easy for
> most of you but somehow the program keeps sending me error messages!
> I have to calculate a new variable that is the total amount of money
> from several variables, all displaied in a row. Rather than using the
> g = var1+var2 etc... which could be annoying considering the amount of
> variables and the fact that I have to repeat this command several
> times I was trying to look on internet for a solution. From this
> statalist I found users who suggested to use the command rowtotal but
> apparently I can`t use it on stata 11, my version. Is it correct? It
> keeps saying "unknow function rowtotal ()"
> Could you please indicate me the right command to use? many thanks
*   For searches and help try:

© Copyright 1996–2018 StataCorp LLC   |   Terms of use   |   Privacy   |   Contact us   |   Site index