Notice: On April 23, 2014, Statalist moved from an email list to a forum, based at statalist.org.
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
st: Sum up different values/inputs from different issues in a new variable
From
"h0650669 (Abdullah Uenal)" <[email protected]>
To
[email protected]
Subject
st: Sum up different values/inputs from different issues in a new variable
Date
Wed, 10 Apr 2013 15:05:03 +0200
v1 v115 v116 v117 v126 v127 v128
31532 o_t1 1.5 0.16 o_a3 0.12 1.23
31532 o_t5 2.0 0.87 o_a4 1.39 13.49
31532 o_t9 2.3 4.94 o_a4 3.49 1.30
31712 o_t3 4.5 2.30 o_a3 4.49 4.09
31712 o_t1 5.5 1.09 o_a14 3.90 1.29
31712 o_t3 1.4 23.09 o_a1 3.09 1.49
31712 o_t8 4.5 1.29 o_a9 1.39 1.57
31809 o_t14 4.6 1.34 o_a3 2.40 2.59
31809 o_t1 2.3 1.98 o_a8 1.49 1.98
Dear all,
First I hope this message finds you well. I am very new to STATA and
have something important to be done until this evening. Hence, I am
tried quite a lot of commands, but was not successful unfortunately.
What I have to do here is the following:
1) Take the issue 31532 from v1, sum up the v116 value of each input of v115.
2) Build a new variable (e.g. v300) for each v115 and sum up v116
according to the input (e.g. otype_t1) of v115.
As an example, the following should demonstrate:
v1 v300 (o_t3 sum of v116) v301 (o_t3 sum of v117)
31712 5.9 25.39
I hope this is somehow clear and I would appreciate a response and
help very much!
Thanks for everthing and have a good day,
Abdullah
*
* For searches and help try:
* http://www.stata.com/help.cgi?search
* http://www.stata.com/support/faqs/resources/statalist-faq/
* http://www.ats.ucla.edu/stat/stata/