Statalist


[Date Prev][Date Next][Thread Prev][Thread Next][Date index][Thread index]

st: RE: Consolidating data


From   "John Wagai" <jwagai@nairobi.kemri-wellcome.org>
To   <statalist@hsphsun2.harvard.edu>
Subject   st: RE: Consolidating data
Date   Tue, 15 Jul 2008 08:38:15 +0300

collapse (sum) sales, by ( product_name company)

-----Original Message-----
From: owner-statalist@hsphsun2.harvard.edu
[mailto:owner-statalist@hsphsun2.harvard.edu] On Behalf Of Kumar, M.V.
Shyam
Sent: 15 July 2008 07:04
To: statalist@hsphsun2.harvard.edu
Subject: st: Consolidating data

Dear Statalisters:

I have a data set which looks as follows:

Company                             Product name                   Sales

Company A                         Product 1
50

Company A                         Product 1
150

Company A                         Product 2
500

Company B                         Product 3
200

Company B                         Product 4
200

Company B                         Product 4
400

And so on.....

I need to consolidate (i.e. add) the sales of products within each
company and produce a data set which appears as follows. 

Company A                         Product 1
200

Company A                         Product 2
500

Company B                         Product 3
200

Company B                         Product 4
600

Some of you may be familiar with this problem. The data set as it
appears on top is product segment data in Compustat reported according
to FASB's SFAS 131. It is based on management's internal reporting
standards. My purpose is to reconfigure the data so that it is based on
distinguishable products and is along the lines of SFAS 13. I have made
some attempts to do this using bysort but that does not work. Any help
would be much appreciated and sincere apologies if this already been
addressed earlier. Thank you. 

Shyam Kumar

Assitant Professor, Lally School of Managmenet

RPI. 


*
*   For searches and help try:
*   http://www.stata.com/support/faqs/res/findit.html
*   http://www.stata.com/support/statalist/faq
*   http://www.ats.ucla.edu/stat/stata/

15/7/2008
"This e-mail (including any attachment to it) contains information
which is confidential. It is intended only for the use of the named
recipient. If you have received this e-mail in error, please let us know
by replying to the sender, and immediately delete it from your system.
Please note, that in these circumstances, the use, disclosure,
distribution or copying of this information is strictly prohibited. We
apologize for any inconvenience that may have been caused to you.
KEMRI-Wellcome Trust cannot accept any responsibility for the accuracy
or completeness of this message as it has been transmitted over a public
network. The Unit reserves the right to monitor all incoming and
outgoing email traffic. Although the Unit has taken reasonable
precautions to ensure no viruses are present in emails, the Unit cannot
accept responsibility for any loss or damage arising from the use of the
email or attachments. Any views expressed in this message are those of
the individual sender, except where the sender specifically states them
to be the views of KEMRI- Wellcome Trust Research".

*
*   For searches and help try:
*   http://www.stata.com/support/faqs/res/findit.html
*   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   |   What's new   |   Site index