Thanks to Nick's excellent support, I have found the solution.
On 10/31/06, Nick Cox <[email protected]> wrote:
See the FAQ
How do I create variables summarizing for each individual
properties of the other members of a group?
http://www.stata.com/support/faqs/data/members.html
Nick
[email protected]
Quang Nguyen
> I have the following data set:
>
> > Vessel Date of landing Revenue
> > 1 July/05/2004
> > 2
> > 3
> > .....
> >
> I would like to create a variable whose value is the average revenue
> of all other vessels having the same date of landing. For instance,
> for vessel 1, this variable will be the average revenue of all other
> vessels (not including vessel 1) whose date of landing is
> July/05/2004.
*
* 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/
*
* 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/