Bookmark and Share

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: How to code |x_i-x_j| in stata?


From   "LI Mengjia" <[email protected]>
To   [email protected]
Subject   st: How to code |x_i-x_j| in stata?
Date   Thu, 10 Oct 2013 11:09:15 +0800 (CST)

Dear statalist,

I'm trying to calculate a "locational Gini coefficient" (rg) by using the formula in a reference paper in the following:

rg=(sum|x_i-x_j|)/(2*n^2*u)

where n is the total number of industries in an area, i and j are just two industries in n industries, x is the market share of any industry, and u is the mean of x.

I have not idea how to put x_i-x_j into stata.

Thanks and best regards,
Amy
*
*   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/


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