Bookmark and Share

Notice: On March 31, it was announced that Statalist is moving from an email list to a forum. The old list will shut down on April 23, and its replacement, statalist.org is already up and running.


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

Re: st: Ho to combine multiple variables into one numeric variable


From   Nick Cox <njcoxstata@gmail.com>
To   "statalist@hsphsun2.harvard.edu" <statalist@hsphsun2.harvard.edu>
Subject   Re: st: Ho to combine multiple variables into one numeric variable
Date   Sat, 28 Jul 2012 14:05:51 +0100

One of my great-grandfathers was Welsh, the language some readers may not recognise here.

Nia should check out row functions in -egen-.

Nick

On 27 Jul 2012, at 15:49, Nia Wyn Williams <abse4a@bangor.ac.uk> wrote:

Dear Stata users

I have monthly deposit rate data for numerous institutions. For some there are multiple observations for each month.
I have details of the deposit rates for 9 different account balances.

So in my file I have columns for the year, month, institution ID and also 9 columns for the deposit rates for the different account balances. How can I combine the deposit rates for the 9 different account balances into one variable, still corresponding to the relevant month? I need to calculate monthly averages, max and min for the overall deposit rates.

Kind Regards,

Nia

--
Rhif Elusen Gofrestredig / Registered Charity No. 1141565

Gall y neges e-bost hon, ac unrhyw atodiadau a anfonwyd gyda hi,
gynnwys deunydd cyfrinachol ac wedi eu bwriadu i'w defnyddio'n unig
gan y sawl y cawsant eu cyfeirio ato (atynt). Os ydych wedi derbyn y
neges e-bost hon trwy gamgymeriad, rhowch wybod i'r anfonwr ar
unwaith a dilëwch y neges. Os na fwriadwyd anfon y neges atoch chi,
rhaid i chi beidio â defnyddio, cadw neu ddatgelu unrhyw wybodaeth a
gynhwysir ynddi. Mae unrhyw farn neu safbwynt yn eiddo i'r sawl a'i
hanfonodd yn unig  ac nid yw o anghenraid yn cynrychioli barn
Prifysgol Bangor. [snip]

*
*   For searches and help try:
*   http://www.stata.com/help.cgi?search
*   http://www.stata.com/support/statalist/faq
*   http://www.ats.ucla.edu/stat/stata/


© Copyright 1996–2014 StataCorp LP   |   Terms of use   |   Privacy   |   Contact us   |   Site index