SlideShare une entreprise Scribd logo
1  sur  53
Télécharger pour lire hors ligne
An introduction to power laws

         Colin Gillespie



       November 15, 2012
Talk outline




1   Introduction to power laws
2   Distributional properties
3   Parameter inference
4   Power law generating mechanisms




                                      http://xkcd.com/
Classic example: distribution of US cities

                                                                                        q
                                                                        2000




                                             No. of Cities
                                                                        1500
   Some data sets vary over enormous
                                                                        1000
   range
                                                                         500
   US towns & cities:                                                                           q

                                                                                                     q
                                                                                                         q qqq qq qq q q q q q
        Duffield (pop 52)                                                      0                               q qqq qq
                                                                                                                   q q

                                                                                                    5
        New York City (pop 8 mil)                                                 10  4.5
                                                                                                10          105.5 106 106.5 107
                                                                                                 City population
   The data is highly right-skewed




                                             Cumulative No. of Cities
                                                                                  q

   When the data is plotted on a                                        103                 q

   logarithmic scale, it seems to follow a                                                       q
                                                                                                        q
                                                                        102                                 q
   straight line                                                                                                qq
                                                                                                                  q
                                                                                                                   qqqq
                                                                                                                          q
                                                                                                                          qqq
   This observation is attributed to Zipf                               101                                                  q   q
                                                                                                                                 qq
                                                                                                                                   q
                                                                                                                                       q
                                                                                                                                            q

                                                                        100                                                                     q


                                                                                        105                 105.5          106             106.5
                                                                                                City population
Distribution of world cities

                                                  World city populations for 8 countries
                                                            logsize vs logrank
                            107.5
                                       New York

                                       Mumbai (Bombay)
                                                           São Paulo
                                                            Delhi      Djakarta
                                                                Los Angeles
                                                                                  Shanghai
                                                                  Kolkata (Calcutta)
                                                                                         Moscou

                                                                                     Lagos
           Log Population




                                                                                               Pékin (Beijing)
                                                                                  Rio de Janeiro   Chicago
                                                                                                Ruhr
                                  7
                             10                                                                        Hong Kong (Xianggang)
                                                                                             Washington
                                                                                                          Chongqing
                                                                                             ChennaiBoston San Francisco − San José
                                                                                                     (Madras)
                                                                                                      ShenyangDallas − Fort Worth
                                                                                                            TianjinBangalore
                                                                                                          Hyderabad Philadelphie
                                                                                                                 Detroit Bandung
                                                                                                                 Houston Miami
                                                                                                      Canton (Guangzhou) Atlanta
                                                                                                                 Ahmadabad Belo Horizonte
                                                                                                                               Pune
                                                                                                          San Diego − Tijuana Ibadan
                                                                                                                            Xian
                                                                                                               Saint−Petersbourg Harbin
                                                                                                                            Wuhan Shantou
                                                                                                                            Chengdu Hangzhou
                                                                                                                              Phoenix Kano
                                                                                                                               Nanjing Medan − Saint−Petersburg
                                                                                                                                 Seattle Tampa Alegre
                                                                                                                                   Berlin Surabaya
                                                                                                                                           Porto
                                                                                                                                   Recife
                                                                                                                               Minneapolis Salvador
                                                                                                                                     CuritibaKanpur
                                                                                                                                       Jinan
                            106.5
                                                                                                                                       BrasiliaFortaleza
                                                                                                                                     CincinnatiCleveland
                                                                                                                                                 Hambourg
                                                                                                                                       Francfort Surat
                                                                                                                                     Changchun Jaipur
                                                                                                                                         Lucknow Denver
                                                                                                                                     Shijiazhuang Saint−Louis
                                                                                                                                               Dalian Taiyuan
                                                                                                                                                Zibo
                                                                                                      Brownsville − McAllen − Matamoros − Reynosa Orlando
                                                                                                                                               Nagpur Patna
                                                                                                                                            Campinas Portland − Ciudad Juarez
                                                                                                                                               Qingdao Tangshan
                                                                                                                                                          El Paso
                                                                                                                                                Guiyang Pittsburgh
                                                                                                                                                Kunming Sacramento
                                                                                                                                                 Charlotte Belem
                                                                                                                                                    Munich Stuttgart City
                                                                                                                                                    Anshan Salt Lake
                                                                                                                                                  Changsha Bénin
                                                                                                                                                        Wuxi Zhengzhou
                                                                                                                                                    Nanchang Palembang
                                                                                                                                                      Goiânia San Antonio
                                                                                                                                                  Indianapolis Kansas City
                                                                                                                                                     Columbus Indore
                                                                                                                                                      Las Vegas Mirat Harcourt
                                                                                                                                                        Kaduna Jilin
                                                                                                                                                        Lanzhou Port
                                                                                                                                                 Niznij Novgorod Santos Pandang (Macassar)
                                                                                                                                                          Manaus Oshogbo
                                                                                                                                                 Raleigh VadodaraUjung
                                                                                                                                                            Bhopal Cirebon
                                                                                                                                                          −Xinyang Nashik
                                                                                                                                                       Bhubaneswar Ludhiana Beach − Norfolk − Corée du Nord)
                                                                                                                                                             Durham Agra
                                                                                                                                                             ZhanjiangVirginia
                                                                                                                                                               Austin Coimbatore
                                                                                                                                                             Nashville Dandong−Sinuiju (Chine
                                                                                                                                                               Vitoria
                                                                                                                                        Greensboro − Winston−SalemXuzhou
                                                                                                                                                              Luoyang Yogyakarta
                                                                                                                                                         VisakhapatnamUrumqi
                                                                                                                                                               Nanning Semarang
                                                                                                                                     Tanjungkarang (Bandar Lampung)Fuzhou (Bénarès)
                                                                                                                                                                   Kochi Mannheim
                                                                                                                                                                  HuainanVaranasi
                                                                                                                                                                   Rajkot Novosibirsk
                                                                                                                                                                  BielefeldBaotou
                                                                                                                                                                       Aba Volgograd
                                                                                                                                                                   Onitsha Suzhou
                                                                                                                                                                       Hefei Qiqihar
                                                                                                                                                                  Denpasar Samara
                                                                                                                                                                    Handan Leipzig−Halle
                                                                                                                                                                    São Luis Louisville
                                                                                                                                                               GrandAsansolRostov
                                                                                                                                                                     Madurai Datong
                                                                                                                                                                       Rapids Iekaterinburg
                                                                                                                                                                     Allahabad Bengbu
                                                                                                                                                                       Mataram Jacksonville
                                                                                                                                                                        Ningbo
                                                                                                                                                      Greenville − Jamshedpur Memphis City
                                                                                                                                                                   Spartanburg Oklahoma
                                                                                                                                                                          Natal
                                                                                                                                                                       Surakarta Jabalpur
                                                                                                                                                                       Richmond Tcheliabinsk
                                                                                                                                                                     BirminghamWenzhou
                                                                                                                                                                      Nuremberg Tegal
                                                                                                                                                                        Dhanbad Maisuru
                                                                                                                                                              Chemnitz−ZwickauRongcheng
                                                                                                                                                                      OgbomoshoAmritsar
                                                                                                                                                                           Brême Buffalo
                                                                                                                                                                            Maceio Aurangabad
                                                                                                                                                                            Hohhot Nouvelle−Orléans
                                                                                                                                                                          RochesterMaiduguri
                                                                                                                                                                             Daqing Zhangjiakou
                                                                                                                                                                            TeresinaVijayawada
                                                                                                                                                       Saarbruck−Forbach Hanovre Albany
                                                                                                                                                                             (France)Omsk
                                                                                                                                                                               Abuja Bhilai
                                                                                                                                                                               AomenSholapur
                                                                                                                                                                              SaratovKazan
                                                                                                                                                                              BaodingSrinagar
                                                                                                                                                                               Dresde Pingxiang
                                                                                                                                                                 Thiruvananthapuram Benxi Pessoa
                                                                                                                                                                             Zhenjiang Xianyang
                             106
                                                                                                                                                                           Chandigarh Ranchi
                                                                                                                                                                              Guwahati Fresno
                                                                                                                                                                            Krasnojarsk Joao
                                                                                                                                                                              Kozhikkod Knoxville
                                                                                                                                                                                    Ufa Samarinda
                                                                                                                                                                                         Malang
                                                                                                                                                                                         Ilorin
                                                                                                                                                                                         Tucson




                                      100                100.5                         101                            101.5                            102
                                                                                         Log Rank

http://brenocon.com/blog/2009/05/zipfs-law-and-world-city-populations/
What does it mean?

  Let p (x )dx be the fraction of cities with a population between x and
  x + dx
  If this histogram is a straight line on log − log scales, then

                             ln p (x ) = −α ln x + c

  where α and c are constants
  Hence
                                 p (x ) = Cx −α

  where C = ec
What does it mean?

  Let p (x )dx be the fraction of cities with a population between x and
  x + dx
  If this histogram is a straight line on log − log scales, then

                             ln p (x ) = −α ln x + c

  where α and c are constants
  Hence
                                 p (x ) = Cx −α

  where C = ec
  Distributions of this form are said to follow a power law
  The constant α is called the exponent of the power law
  We typically don’t care about c.
The power law distribution


     Name          f (x )                      Notes
     Power law     x −α                        Pareto distribution
     Exponential   e − λx
                   1            (ln x −µ)2
     log-normal    x
                       exp(−        2σ 2
                                           )
     Power law     x −α                        Zeta distribution
     Power law     x −α                        x = 1, . . . , n, Zipf’s dist’
                     Γ (x )
     Yule          Γ (x + α )
     Poisson       λx /x !
Alleged power-law phenomena

 The frequency of occurrence of unique words in the novel Moby Dick by
 Herman Melville
 The numbers of customers affected in electrical blackouts in the United
 States between 1984 and 2002
 The number of links to web sites found in a 1997 web crawl of about 200
 million web pages
Alleged power-law phenomena

 The frequency of occurrence of unique words in the novel Moby Dick by
 Herman Melville
 The numbers of customers affected in electrical blackouts in the United
 States between 1984 and 2002
 The number of links to web sites found in a 1997 web crawl of about 200
 million web pages
 The number of hits on web pages
 The number of papers scientist write
 The number of citations received by papers
 Annual incomes
 Sales of books, music; in fact anything that can be sold
Zipf plots

                       Blackouts                  Fires                       Flares
          100


          10−2


          10−4


          10−6


          10−8
 1−P(x)




                       Moby Dick                Terrorism                   Web links
          100


          10−2


          10−4


          10−6


          10−8

                 100   102    104   106   100   102       104   106   100   102    104   106
                                                      x
Distributional properties
The power law distribution

  The power-law distribution is

                                  p (x ) ∝ x − α

  where α, the scaling parameter, is a constant
  The scaling parameter typically lies in the range 2 < α < 3, although
  there are some occasional exceptions
  Typically, the entire process doesn’t obey a power law
  Instead, the power law applies only for values greater than some
  minimum xmin
Power law: PDF & CDF

                                                               α
                                                               1.50 1.75 2.00 2.25 2.50


  For the continuous PL, the pdf is          1.5
                                                                       PDF



                                      −α
                    α−1         x            1.0

         p (x ) =
                    xmin     xmin            0.5



  where α > 1 and xmin > 0.                  0.0
                                                                       CDF
  The CDF is:                                1.5



                                    − α +1   1.0
                            x
         P (x ) = 1 −
                           xmin              0.5



                                             0.0
                                                   0.0   2.5            5.0          7.5   10.0
                                                                         x
Power law: PDF & CDF

                                                              α
  For the discrete power law, the pmf is                      1.50 1.75 2.00 2.25 2.50

                                                                      PDF

                               x −α         1.5

             p (x ) =
                        ζ (α, xmin )        1.0



  where                                     0.5



                         ∞                  0.0

       ζ (α, xmin ) =   ∑ (n + xmin )−α     1.5
                                                                      CDF


                        n =0
                                            1.0
  is the generalised zeta function
                                            0.5
  When xmin = 1, ζ (α, 1) is the standard
  zeta function                             0.0
                                                  0.0   2.5            5.0          7.5   10.0
                                                                        x
Moments

Moments:
                                 ∞                      α−1
             x m = E [X m ] =          x m p (x ) =            xm
                                xmin                  α − 1 − m min
Hence, when m ≥ α − 1, we have diverging moments
Moments

Moments:
                                  ∞                      α−1
              x m = E [X m ] =          x m p (x ) =            xm
                                 xmin                  α − 1 − m min
Hence, when m ≥ α − 1, we have diverging moments

So when
    α < 2, all moments are infinite
    α < 3, all second and higher-order moments are infinite
    α < 4, all third order and higher-order moments are infinite
    ....
Distributional properties

For any power law with exponent α > 1, the median is defined:

                           x1/2 = 21/(α−1) xmin
Distributional properties

For any power law with exponent α > 1, the median is defined:

                                     x1/2 = 21/(α−1) xmin

If we use power-law to model wealth distribution, then we might be interested
in the fraction of wealth in the richer half:
                 ∞                               − α +2
                x1 / 2
                         xp (x )dx        x1/2
                 ∞                   =                    = 2−(α−2)/(α−1)
                         xp (x )dx        xmin
                xmin

provided α > 2, the integrals converge
Distributional properties

For any power law with exponent α > 1, the median is defined:

                                     x1/2 = 21/(α−1) xmin

If we use power-law to model wealth distribution, then we might be interested
in the fraction of wealth in the richer half:
                 ∞                               − α +2
                x1 / 2
                         xp (x )dx        x1/2
                 ∞                   =                    = 2−(α−2)/(α−1)
                         xp (x )dx        xmin
                xmin

provided α > 2, the integrals converge


When the wealth distribution was modelled using a power-law, α was
estimated to be 2.1, so 2−0.091  94% of the wealth is in the hands of the
richer 50% of the population
Top-heavy distribution & the 80/20 rule

Pareto principle: aka 80/20 rule
The law of the vital few, and the principle of factor sparsity states that, for many
events, roughly 80% of the effects come from 20% of the causes
Top-heavy distribution & the 80/20 rule

Pareto principle: aka 80/20 rule
The law of the vital few, and the principle of factor sparsity states that, for many
events, roughly 80% of the effects come from 20% of the causes

  For example, the distribution of world GDP

                         Population quantile    Income
                         Richest 20%            82.70%
                         Second 20%             11.75%
                         Third 20%               2.30%
                         Fourth 20%              1.85%
                         Poorest 20%             1.40%

Other examples are:
    80% of your profits come from 20% of your customers
    80% of your complaints come from 20% of your customers
    80% of your profits come from 20% of the time you spend
Scale-free distributions

  The power law distribution is often referred to as a scale-free distribution
  A power law is the only distribution that is the same on regardless of the
  scale
Scale-free distributions

  The power law distribution is often referred to as a scale-free distribution
  A power law is the only distribution that is the same on regardless of the
  scale
  For any b, we have
                              p (bx ) = g (b )p (x )

  That is, if we increase the scale by which we measure x by a factor of b,
  the shape of the distribution p (x ) is unchanged, except for a multiplicative
  constant
  The PL distribution is the only distribution with this property
Random numbers

For the continuous case, we can generate random numbers using the
standard inversion method:

                        x = xmin (1 − u )−1/(α−1)

where U ∼ U (0, 1)
Random numbers

 The discrete case is a bit more tricky
 Instead, we have to solve the CMF numerically by “doubling up” and a
 binary search
Random numbers

 The discrete case is a bit more tricky
 Instead, we have to solve the CMF numerically by “doubling up” and a
 binary search
 So for a given u, we first bound the solution to the equation via:
                          1:   x2 := xmin
                          2:   repeat
                          3:     x1 := x2
                          4:     x2 := 2x1
                          5:   until P (x2 ) < 1 − u
 Basically, the algorithm tests whether u ∈ [x , 2x ), starting with x = xmin
 Once we have the region we use a binary search
Fitting power law distributions
Fitting power law distributions

Suppose we know xmin and wish to estimate the exponent α.
Method 1

  1   Bin your data: [xmin , xmin +                       x ), [xmin +          x , xmin + 2       x)
  2   Plot your data on a log-log plot
  3   Use least squares to estimate α

                             Bin size: 0.01                   Bin size: 0.1                 Bin size: 1.0
               100

               10−1

               10−2
         CDF




               10−3

               10−4

               10−5
                      100   101      102      103   100     101        102    103   100   101      102      103
                                                                   x



You could also use logarithmic binning (which is better) or should I say not as
bad?
Method 2

Similar to method 1, but
     Don’t bin, just plot the data CDF
     Then use least squares to estimate α
     Using linear regression is a bad idea
Method 2

Similar to method 1, but
     Don’t bin, just plot the data CDF
     Then use least squares to estimate α
     Using linear regression is a bad idea
          Error estimates are completely off
          It doesn’t even provide a good point estimate of α
Method 2

Similar to method 1, but
     Don’t bin, just plot the data CDF
     Then use least squares to estimate α
     Using linear regression is a bad idea
          Error estimates are completely off
          It doesn’t even provide a good point estimate of α
          On the bright side you do get a good R 2 value
Method 3: Log-Likelihood

  The log-likelihood isn’t that hard to derive

Continuous:
                                                                 n
                                                                               xi
         (α|x , xmin ) = n log(α − 1) − n log(xmin ) − α ∑ log
                                                                i =1
                                                                              xmin

Discrete:
                                                  n
        (α|x , xmin ) = −n log[ζ (α, xmin )] − α ∑ log(xi )
                                                 i =1
                                                 xmin −1                n
                    = −n log[ζ (α)] + n log        ∑       xi    − α ∑ log(xi )
                                                   i =1                i =1
MLEs

Maximising the log-likelihood gives
                                                         −1
                                         n
                                                  xi
                       ˆ
                       α = 1+n        ∑ ln       xxmin
                                      i =1


An estimate of the associated error is
                                    α−1
                                  σ= √
                                             n
MLEs

Maximising the log-likelihood gives
                                                              −1
                                          n
                                                      xi
                        ˆ
                        α = 1+n          ∑ ln        xxmin
                                         i =1


An estimate of the associated error is
                                    α−1
                                  σ= √
                                                 n

The discrete case is a bit more tricky and involves ignoring higher order terms,
to get:
                                                                   −1
                                   n
                                                      xi
                    ˆ
                    α    1+n      ∑ ln          xxmin − 0.5
                                  i =1
Estimating xmin

  Recall that the power-law pdf is
                                                     −α
                                      α−1      x
                           p (x ) =
                                      xmin    xmin

  where α > 1 and xmin > 0
  xmin isn’t a parameter in the usual since - it’s a cut-off in the state space
  Typically power-laws are only present in the distributional tails.
  So how much of the data should we discard so our distribution fits a
  power-law?
Estimating xmin : method 1

 The most common way is just look at the
 log-log plot
 What could be easier!

                                  Blackouts                  Fires                       Flares
                     100


                     10−2


                     10−4


                     10−6


                     10−8
            1−P(x)




                                  Moby Dick                Terrorism                   Web links
                     100


                     10−2


                     10−4


                     10−6


                     10−8

                            100   102    104   106   100   102       104   106   100   102    104   106
                                                                 x
Estimating xmin : method 2

  Use a "Bayesian approach" - the BIC:

                        −2 + k ln n = −2 + xmin ln n

  Increasing xmin increases the number of parameters
  Only suitable for discrete distributions
Estimating xmin : method 3

  Minimise the distance between the data and the fitted model CDFs:

                          D = max |S (x ) − P (x )|
                               x ≥xmin


  where S (x ) is the CDF of the data and P (x ) is the theoretical CDF (the
  Kolmogorov-Smirnov statistic)
  Our estimate xmin is then the value of xmin that minimises D
  Use some form of bootstrapping to get a handle on uncertainty of xmin
Mechanisms for generating PL distributions
Word distributions

    Suppose we type randomly on a
    typewriter
    We hit the space bar with probability qs
    and a letter with probability ql
    If there are m letters in the alphabet,
    then
                 ql = (1 − qs )/m

                                               http://activerain.com/
Word distributions

    Suppose we type randomly on a
    typewriter
    We hit the space bar with probability qs
    and a letter with probability ql
    If there are m letters in the alphabet,
    then
                 ql = (1 − qs )/m

    The distribution of word frequency has     http://activerain.com/
    the form p (x ) ∼ x −α
Relationship between α value and Zipf’s principle of least
effort.



α value       Examples in literature                       Least effort for
α < 1.6       Advanced schizophrenia
1.6 ≤ α < 2   Military combat texts, Wikipedia, Web        Annotator
              pages listed on the open directory project
α=2           Single author texts                          Equal effort levels
2 < α ≤ 2.4   Multi author texts                           Audience
α > 2.4       Fragmented discourse schizophrenia
Random walks

 Suppose we have a 1d random walk
 At each unit of time, we move ±1
                  4                                   q


                                                  q       q                                                 q


                  2           q               q               q                                        q        q


                          q       q       q                        q       q                       q                q
      Position




                  0   q
                      q               q
                                      q                                q
                                                                       q       q
                                                                               q               q
                                                                                               q                        q
                                                                                                                        q


                                                                                   q       q                                q       q       q


                 −2                                                                    q                                        q       q       q




                 −4

                      0                                       10                                       20                                       30
                                                                               Time
Random walks

 Suppose we have a 1d random walk
 At each unit of time, we move ±1
                  4                                   q


                                                  q       q                                                 q


                  2           q               q               q                                        q        q


                          q       q       q                        q       q                       q                q
      Position




                  0   q
                      q               q
                                      q                                q
                                                                       q       q
                                                                               q               q
                                                                                               q                        q
                                                                                                                        q


                                                                                   q       q                                q       q       q


                 −2                                                                    q                                        q       q       q




                 −4

                      0                                       10                                       20                                       30
                                                                               Time

 If we start at n = 0, what is the probability for the first return time at time t
Random walks

 With a bit of algebra, we get:
                                           n
                                         (2n)
                             f2n   =
                                     (2n − 1)22n
 For large n, we get
                                           2
                            f2n
                                       n (2n − 1)2

 So as n → ∞, we get
                                   f2n ∼ n−3/2

 So the distribution of return times follows a power law with exponent
 α = 3/2!
Random walks

 With a bit of algebra, we get:
                                           n
                                         (2n)
                             f2n   =
                                     (2n − 1)22n
 For large n, we get
                                           2
                            f2n
                                       n (2n − 1)2

 So as n → ∞, we get
                                   f2n ∼ n−3/2

 So the distribution of return times follows a power law with exponent
 α = 3/2!
 Tenuous link to phylogenetics
Phase transitions and critical phenomena

   Suppose we have a simple lattice. Each
   square is coloured with probability
   p = 0.5
   We can look at the clusters of coloured
   squares. For example, the mean cluster
   area, s , of a randomly chosen square:

       If a square is white, then zero
       If a square is coloured, but surround
       by white, then one
       etc
Phase transitions and critical phenomena

   Suppose we have a simple lattice. Each
   square is coloured with probability
   p = 0.5
   We can look at the clusters of coloured
   squares. For example, the mean cluster
   area, s , of a randomly chosen square:

       If a square is white, then zero
       If a square is coloured, but surround
       by white, then one
       etc
   When p is small, s is independent of
   the lattice size
   When p is large, s depends on the
   lattice size
Phase transitions and critical phenomena




                                                 p=0.3
   As we increase p, the value of s also
   increases
   For some p, s starts to increase with
   the lattice size




                                                 p=0.5927...
   This is know as the critical value, and is
   p = pc = 0.5927462..
   If we calculate the distribution of p (s ),
   then when p = pc , p (s ) follows a
   power-law distribution




                                                 p=0.9
Forest fire

This simple model has been used as a primitive model of forest fires
  We start with an empty lattice and trees grow at random
  Every so often, a forest fire strikes at random
  If the forest is too connected, i.e. large p, then the forest burns down
  So (it is argued) that the forest size oscillates around p = pc
Forest fire

This simple model has been used as a primitive model of forest fires
  We start with an empty lattice and trees grow at random
  Every so often, a forest fire strikes at random
  If the forest is too connected, i.e. large p, then the forest burns down
  So (it is argued) that the forest size oscillates around p = pc
  This is an example of self-organised criticality
Future work

    There isn’t even an R package for power law estimation
        Writing this talk I have (more or less) written one
    Use a Bayesian change point model to estimate xmin in a vaguely
    sensible way
    RJMCMC to change between the power law and other heavy tailed
    distributions
References
    A. Clauset, C.R. Shalizi, and M.E.J. Newman.
    Power-lawdistributionsinempiricaldata.
    http://arxiv.org/abs/0706.1062
    MEJ Newman. Powerlaws,ParetodistributionsandZipf’slaw.
    http://arxiv.org/abs/cond-mat/0412004

Contenu connexe

Tendances

Sampling distribution
Sampling distributionSampling distribution
Sampling distributionDanu Saputra
 
Chapter 5 part2- Sampling Distributions for Counts and Proportions (Binomial ...
Chapter 5 part2- Sampling Distributions for Counts and Proportions (Binomial ...Chapter 5 part2- Sampling Distributions for Counts and Proportions (Binomial ...
Chapter 5 part2- Sampling Distributions for Counts and Proportions (Binomial ...nszakir
 
Quantum Teleportation with Qiskit
Quantum Teleportation with QiskitQuantum Teleportation with Qiskit
Quantum Teleportation with QiskitDayeong Kang
 
Probabilistic models (part 1)
Probabilistic models (part 1)Probabilistic models (part 1)
Probabilistic models (part 1)KU Leuven
 
Hypothesis Testing-Z-Test
Hypothesis Testing-Z-TestHypothesis Testing-Z-Test
Hypothesis Testing-Z-TestRoger Binschus
 
Random graph models
Random graph modelsRandom graph models
Random graph modelsnetworksuw
 
Intro to Classification: Logistic Regression & SVM
Intro to Classification: Logistic Regression & SVMIntro to Classification: Logistic Regression & SVM
Intro to Classification: Logistic Regression & SVMNYC Predictive Analytics
 
Decision tree and instance-based learning for label ranking
Decision tree and instance-based learning for label rankingDecision tree and instance-based learning for label ranking
Decision tree and instance-based learning for label rankingroywwcheng
 
Chapter 09
Chapter 09Chapter 09
Chapter 09bmcfad01
 
Community Detection in Social Media
Community Detection in Social MediaCommunity Detection in Social Media
Community Detection in Social MediaSymeon Papadopoulos
 
Group and Community Detection in Social Networks
Group and Community Detection in Social NetworksGroup and Community Detection in Social Networks
Group and Community Detection in Social NetworksKent State University
 
Complex Network Analysis
Complex Network Analysis Complex Network Analysis
Complex Network Analysis Annu Sharma
 
Estimation and confidence interval
Estimation and confidence intervalEstimation and confidence interval
Estimation and confidence intervalHomework Guru
 
Community detection in graphs
Community detection in graphsCommunity detection in graphs
Community detection in graphsNicola Barbieri
 

Tendances (20)

Sampling distribution
Sampling distributionSampling distribution
Sampling distribution
 
Chapter 5 part2- Sampling Distributions for Counts and Proportions (Binomial ...
Chapter 5 part2- Sampling Distributions for Counts and Proportions (Binomial ...Chapter 5 part2- Sampling Distributions for Counts and Proportions (Binomial ...
Chapter 5 part2- Sampling Distributions for Counts and Proportions (Binomial ...
 
Causal Bayesian Networks
Causal Bayesian NetworksCausal Bayesian Networks
Causal Bayesian Networks
 
Quantum Teleportation with Qiskit
Quantum Teleportation with QiskitQuantum Teleportation with Qiskit
Quantum Teleportation with Qiskit
 
Probabilistic models (part 1)
Probabilistic models (part 1)Probabilistic models (part 1)
Probabilistic models (part 1)
 
T distribution | Statistics
T distribution | StatisticsT distribution | Statistics
T distribution | Statistics
 
Hypothesis Testing-Z-Test
Hypothesis Testing-Z-TestHypothesis Testing-Z-Test
Hypothesis Testing-Z-Test
 
Random graph models
Random graph modelsRandom graph models
Random graph models
 
Intro to Classification: Logistic Regression & SVM
Intro to Classification: Logistic Regression & SVMIntro to Classification: Logistic Regression & SVM
Intro to Classification: Logistic Regression & SVM
 
Lec 4,5
Lec 4,5Lec 4,5
Lec 4,5
 
randomwalk.ppt
randomwalk.pptrandomwalk.ppt
randomwalk.ppt
 
Decision tree and instance-based learning for label ranking
Decision tree and instance-based learning for label rankingDecision tree and instance-based learning for label ranking
Decision tree and instance-based learning for label ranking
 
Chapter 09
Chapter 09Chapter 09
Chapter 09
 
Community Detection in Social Media
Community Detection in Social MediaCommunity Detection in Social Media
Community Detection in Social Media
 
Bayesian statistics
Bayesian statisticsBayesian statistics
Bayesian statistics
 
Group and Community Detection in Social Networks
Group and Community Detection in Social NetworksGroup and Community Detection in Social Networks
Group and Community Detection in Social Networks
 
Complex Network Analysis
Complex Network Analysis Complex Network Analysis
Complex Network Analysis
 
Estimation and confidence interval
Estimation and confidence intervalEstimation and confidence interval
Estimation and confidence interval
 
Biot savart law
Biot savart lawBiot savart law
Biot savart law
 
Community detection in graphs
Community detection in graphsCommunity detection in graphs
Community detection in graphs
 

En vedette

Intro To Power Laws (March 2008)
Intro To Power Laws (March 2008)Intro To Power Laws (March 2008)
Intro To Power Laws (March 2008)Socialphysicist
 
Gamification and the Brain | Kyle Findlay
Gamification and the Brain | Kyle FindlayGamification and the Brain | Kyle Findlay
Gamification and the Brain | Kyle FindlaySocialphysicist
 
How Attention Works - Kyle Findlay - TNS Global
How Attention Works - Kyle Findlay - TNS GlobalHow Attention Works - Kyle Findlay - TNS Global
How Attention Works - Kyle Findlay - TNS GlobalIgnasi Pardo
 
Network Theory: A Brief Introduction june 2012
Network Theory: A Brief Introduction june 2012Network Theory: A Brief Introduction june 2012
Network Theory: A Brief Introduction june 2012Michael Netzley, Ph.D.
 
The shape of brand conversations
The shape of brand conversationsThe shape of brand conversations
The shape of brand conversationsSocialphysicist
 
User behavior model & recommendation on basis of social networks
User behavior model & recommendation on basis of social networks User behavior model & recommendation on basis of social networks
User behavior model & recommendation on basis of social networks Shah Alam Sabuj
 
the near future of tourism services based on digital traces
the near future of tourism services based on digital tracesthe near future of tourism services based on digital traces
the near future of tourism services based on digital tracesnicolas nova
 
Urban Agents and Citizen Apps
Urban Agents and Citizen AppsUrban Agents and Citizen Apps
Urban Agents and Citizen AppsFabio Carrera
 
Multidimensional Patterns of Disturbance in Digital Social Networks
Multidimensional Patterns of Disturbance in Digital Social NetworksMultidimensional Patterns of Disturbance in Digital Social Networks
Multidimensional Patterns of Disturbance in Digital Social NetworksDimitar Denev
 
Designing The Social In
Designing The Social InDesigning The Social In
Designing The Social InErin Malone
 
R5 What Is The Impact Of Urban Activities
R5 What Is The Impact Of Urban ActivitiesR5 What Is The Impact Of Urban Activities
R5 What Is The Impact Of Urban ActivitiesSHS Geog
 
Unmetric facebook analysis
Unmetric facebook analysisUnmetric facebook analysis
Unmetric facebook analysisBalvor LLC
 
User Behaviour Pattern Recognition On Twitter Social Network
User Behaviour Pattern Recognition On Twitter Social NetworkUser Behaviour Pattern Recognition On Twitter Social Network
User Behaviour Pattern Recognition On Twitter Social NetworkGeorge Konstantakopoulos
 
CSCW 2011 Talk on "Activity Analysis"
CSCW 2011 Talk on "Activity Analysis"CSCW 2011 Talk on "Activity Analysis"
CSCW 2011 Talk on "Activity Analysis"Jakob Bardram
 
Points of distribution
Points of distributionPoints of distribution
Points of distributionChatham EMA
 
Impact of Urban Logistics of Commercial Vehicles
Impact of Urban Logistics of Commercial Vehicles  Impact of Urban Logistics of Commercial Vehicles
Impact of Urban Logistics of Commercial Vehicles Sandeep Kar
 

En vedette (20)

Intro To Power Laws (March 2008)
Intro To Power Laws (March 2008)Intro To Power Laws (March 2008)
Intro To Power Laws (March 2008)
 
Gamification and the Brain | Kyle Findlay
Gamification and the Brain | Kyle FindlayGamification and the Brain | Kyle Findlay
Gamification and the Brain | Kyle Findlay
 
How Attention Works - Kyle Findlay - TNS Global
How Attention Works - Kyle Findlay - TNS GlobalHow Attention Works - Kyle Findlay - TNS Global
How Attention Works - Kyle Findlay - TNS Global
 
Network Theory: A Brief Introduction june 2012
Network Theory: A Brief Introduction june 2012Network Theory: A Brief Introduction june 2012
Network Theory: A Brief Introduction june 2012
 
The shape of brand conversations
The shape of brand conversationsThe shape of brand conversations
The shape of brand conversations
 
Media Wave Platform
Media Wave PlatformMedia Wave Platform
Media Wave Platform
 
User behavior model & recommendation on basis of social networks
User behavior model & recommendation on basis of social networks User behavior model & recommendation on basis of social networks
User behavior model & recommendation on basis of social networks
 
4 urbact iufn
4 urbact iufn4 urbact iufn
4 urbact iufn
 
the near future of tourism services based on digital traces
the near future of tourism services based on digital tracesthe near future of tourism services based on digital traces
the near future of tourism services based on digital traces
 
Urban Agents and Citizen Apps
Urban Agents and Citizen AppsUrban Agents and Citizen Apps
Urban Agents and Citizen Apps
 
Multidimensional Patterns of Disturbance in Digital Social Networks
Multidimensional Patterns of Disturbance in Digital Social NetworksMultidimensional Patterns of Disturbance in Digital Social Networks
Multidimensional Patterns of Disturbance in Digital Social Networks
 
Designing The Social In
Designing The Social InDesigning The Social In
Designing The Social In
 
R5 What Is The Impact Of Urban Activities
R5 What Is The Impact Of Urban ActivitiesR5 What Is The Impact Of Urban Activities
R5 What Is The Impact Of Urban Activities
 
Urban Impact Framework
Urban Impact FrameworkUrban Impact Framework
Urban Impact Framework
 
Unmetric facebook analysis
Unmetric facebook analysisUnmetric facebook analysis
Unmetric facebook analysis
 
User Behaviour Pattern Recognition On Twitter Social Network
User Behaviour Pattern Recognition On Twitter Social NetworkUser Behaviour Pattern Recognition On Twitter Social Network
User Behaviour Pattern Recognition On Twitter Social Network
 
CSCW 2011 Talk on "Activity Analysis"
CSCW 2011 Talk on "Activity Analysis"CSCW 2011 Talk on "Activity Analysis"
CSCW 2011 Talk on "Activity Analysis"
 
Zipf distribution
Zipf distributionZipf distribution
Zipf distribution
 
Points of distribution
Points of distributionPoints of distribution
Points of distribution
 
Impact of Urban Logistics of Commercial Vehicles
Impact of Urban Logistics of Commercial Vehicles  Impact of Urban Logistics of Commercial Vehicles
Impact of Urban Logistics of Commercial Vehicles
 

Similaire à An introduction to power laws and their distributional properties

Navigating Molecular Haystacks: Tools & Applications
Navigating Molecular Haystacks: Tools & ApplicationsNavigating Molecular Haystacks: Tools & Applications
Navigating Molecular Haystacks: Tools & ApplicationsRajarshi Guha
 
Example sweavefunnelplot
Example sweavefunnelplotExample sweavefunnelplot
Example sweavefunnelplotTony Hirst
 
Living In The Cloud
Living In The CloudLiving In The Cloud
Living In The Cloudacme
 
Time series compare
Time series compareTime series compare
Time series comparelrhutyra
 
Characterizing the Density of Chemical Spaces and its Use in Outlier Analysis...
Characterizing the Density of Chemical Spaces and its Use in Outlier Analysis...Characterizing the Density of Chemical Spaces and its Use in Outlier Analysis...
Characterizing the Density of Chemical Spaces and its Use in Outlier Analysis...Rajarshi Guha
 
Robust parametric classification and variable selection with minimum distance...
Robust parametric classification and variable selection with minimum distance...Robust parametric classification and variable selection with minimum distance...
Robust parametric classification and variable selection with minimum distance...echi99
 
Regression Modelling Overview
Regression Modelling OverviewRegression Modelling Overview
Regression Modelling OverviewPaul Hewson
 
Parallel Combinatorial Computing and Sparse Matrices
Parallel Combinatorial Computing and Sparse Matrices Parallel Combinatorial Computing and Sparse Matrices
Parallel Combinatorial Computing and Sparse Matrices Jason Riedy
 
Stat7840 hao wu
Stat7840 hao wuStat7840 hao wu
Stat7840 hao wuHao Wu
 
F1 India 2011: Free Practice Summary Stats
F1 India 2011: Free Practice Summary StatsF1 India 2011: Free Practice Summary Stats
F1 India 2011: Free Practice Summary StatsTony Hirst
 
F1 2011 Korea Race Report
F1 2011 Korea Race ReportF1 2011 Korea Race Report
F1 2011 Korea Race ReportTony Hirst
 
Survey of Esoko Users
Survey of Esoko UsersSurvey of Esoko Users
Survey of Esoko UsersEsoko
 

Similaire à An introduction to power laws and their distributional properties (20)

Navigating Molecular Haystacks: Tools & Applications
Navigating Molecular Haystacks: Tools & ApplicationsNavigating Molecular Haystacks: Tools & Applications
Navigating Molecular Haystacks: Tools & Applications
 
Example sweavefunnelplot
Example sweavefunnelplotExample sweavefunnelplot
Example sweavefunnelplot
 
Living In The Cloud
Living In The CloudLiving In The Cloud
Living In The Cloud
 
Time series compare
Time series compareTime series compare
Time series compare
 
Characterizing the Density of Chemical Spaces and its Use in Outlier Analysis...
Characterizing the Density of Chemical Spaces and its Use in Outlier Analysis...Characterizing the Density of Chemical Spaces and its Use in Outlier Analysis...
Characterizing the Density of Chemical Spaces and its Use in Outlier Analysis...
 
Robust parametric classification and variable selection with minimum distance...
Robust parametric classification and variable selection with minimum distance...Robust parametric classification and variable selection with minimum distance...
Robust parametric classification and variable selection with minimum distance...
 
Slides geotop
Slides geotopSlides geotop
Slides geotop
 
Slides GEOTOP
Slides GEOTOPSlides GEOTOP
Slides GEOTOP
 
Regression Modelling Overview
Regression Modelling OverviewRegression Modelling Overview
Regression Modelling Overview
 
Slides lyon-2011
Slides lyon-2011Slides lyon-2011
Slides lyon-2011
 
Parallel Combinatorial Computing and Sparse Matrices
Parallel Combinatorial Computing and Sparse Matrices Parallel Combinatorial Computing and Sparse Matrices
Parallel Combinatorial Computing and Sparse Matrices
 
Slides p6
Slides p6Slides p6
Slides p6
 
Stat7840 hao wu
Stat7840 hao wuStat7840 hao wu
Stat7840 hao wu
 
Slides mcneil
Slides mcneilSlides mcneil
Slides mcneil
 
F1 India 2011: Free Practice Summary Stats
F1 India 2011: Free Practice Summary StatsF1 India 2011: Free Practice Summary Stats
F1 India 2011: Free Practice Summary Stats
 
Clustering Plot
Clustering PlotClustering Plot
Clustering Plot
 
F1 2011 Korea Race Report
F1 2011 Korea Race ReportF1 2011 Korea Race Report
F1 2011 Korea Race Report
 
Survey of Esoko Users
Survey of Esoko UsersSurvey of Esoko Users
Survey of Esoko Users
 
Slides alexander-mcneil
Slides alexander-mcneilSlides alexander-mcneil
Slides alexander-mcneil
 
Slides binar-hec
Slides binar-hecSlides binar-hec
Slides binar-hec
 

Plus de Colin Gillespie

Bayesian Experimental Design for Stochastic Kinetic Models
Bayesian Experimental Design for Stochastic Kinetic ModelsBayesian Experimental Design for Stochastic Kinetic Models
Bayesian Experimental Design for Stochastic Kinetic ModelsColin Gillespie
 
The tau-leap method for simulating stochastic kinetic models
The tau-leap method for simulating stochastic kinetic modelsThe tau-leap method for simulating stochastic kinetic models
The tau-leap method for simulating stochastic kinetic modelsColin Gillespie
 
Poster for Information, probability and inference in systems biology (IPISB 2...
Poster for Information, probability and inference in systems biology (IPISB 2...Poster for Information, probability and inference in systems biology (IPISB 2...
Poster for Information, probability and inference in systems biology (IPISB 2...Colin Gillespie
 
Reference classes: a case study with the poweRlaw package
Reference classes: a case study with the poweRlaw packageReference classes: a case study with the poweRlaw package
Reference classes: a case study with the poweRlaw packageColin Gillespie
 
Moment Closure Based Parameter Inference of Stochastic Kinetic Models
Moment Closure Based Parameter Inference of Stochastic Kinetic ModelsMoment Closure Based Parameter Inference of Stochastic Kinetic Models
Moment Closure Based Parameter Inference of Stochastic Kinetic ModelsColin Gillespie
 
An introduction to moment closure techniques
An introduction to moment closure techniquesAn introduction to moment closure techniques
An introduction to moment closure techniquesColin Gillespie
 
Speeding up the Gillespie algorithm
Speeding up the Gillespie algorithmSpeeding up the Gillespie algorithm
Speeding up the Gillespie algorithmColin Gillespie
 
Moment closure inference for stochastic kinetic models
Moment closure inference for stochastic kinetic modelsMoment closure inference for stochastic kinetic models
Moment closure inference for stochastic kinetic modelsColin Gillespie
 
Bayesian inference for stochastic population models with application to aphids
Bayesian inference for stochastic population models with application to aphidsBayesian inference for stochastic population models with application to aphids
Bayesian inference for stochastic population models with application to aphidsColin Gillespie
 

Plus de Colin Gillespie (10)

Bayesian Experimental Design for Stochastic Kinetic Models
Bayesian Experimental Design for Stochastic Kinetic ModelsBayesian Experimental Design for Stochastic Kinetic Models
Bayesian Experimental Design for Stochastic Kinetic Models
 
The tau-leap method for simulating stochastic kinetic models
The tau-leap method for simulating stochastic kinetic modelsThe tau-leap method for simulating stochastic kinetic models
The tau-leap method for simulating stochastic kinetic models
 
Poster for Information, probability and inference in systems biology (IPISB 2...
Poster for Information, probability and inference in systems biology (IPISB 2...Poster for Information, probability and inference in systems biology (IPISB 2...
Poster for Information, probability and inference in systems biology (IPISB 2...
 
Reference classes: a case study with the poweRlaw package
Reference classes: a case study with the poweRlaw packageReference classes: a case study with the poweRlaw package
Reference classes: a case study with the poweRlaw package
 
Moment Closure Based Parameter Inference of Stochastic Kinetic Models
Moment Closure Based Parameter Inference of Stochastic Kinetic ModelsMoment Closure Based Parameter Inference of Stochastic Kinetic Models
Moment Closure Based Parameter Inference of Stochastic Kinetic Models
 
An introduction to moment closure techniques
An introduction to moment closure techniquesAn introduction to moment closure techniques
An introduction to moment closure techniques
 
Speeding up the Gillespie algorithm
Speeding up the Gillespie algorithmSpeeding up the Gillespie algorithm
Speeding up the Gillespie algorithm
 
Moment closure inference for stochastic kinetic models
Moment closure inference for stochastic kinetic modelsMoment closure inference for stochastic kinetic models
Moment closure inference for stochastic kinetic models
 
WCSB 2012
WCSB 2012 WCSB 2012
WCSB 2012
 
Bayesian inference for stochastic population models with application to aphids
Bayesian inference for stochastic population models with application to aphidsBayesian inference for stochastic population models with application to aphids
Bayesian inference for stochastic population models with application to aphids
 

An introduction to power laws and their distributional properties

  • 1. An introduction to power laws Colin Gillespie November 15, 2012
  • 2. Talk outline 1 Introduction to power laws 2 Distributional properties 3 Parameter inference 4 Power law generating mechanisms http://xkcd.com/
  • 3. Classic example: distribution of US cities q 2000 No. of Cities 1500 Some data sets vary over enormous 1000 range 500 US towns & cities: q q q qqq qq qq q q q q q Duffield (pop 52) 0 q qqq qq q q 5 New York City (pop 8 mil) 10 4.5 10 105.5 106 106.5 107 City population The data is highly right-skewed Cumulative No. of Cities q When the data is plotted on a 103 q logarithmic scale, it seems to follow a q q 102 q straight line qq q qqqq q qqq This observation is attributed to Zipf 101 q q qq q q q 100 q 105 105.5 106 106.5 City population
  • 4. Distribution of world cities World city populations for 8 countries logsize vs logrank 107.5 New York Mumbai (Bombay) São Paulo Delhi Djakarta Los Angeles Shanghai Kolkata (Calcutta) Moscou Lagos Log Population Pékin (Beijing) Rio de Janeiro Chicago Ruhr 7 10 Hong Kong (Xianggang) Washington Chongqing ChennaiBoston San Francisco − San José (Madras) ShenyangDallas − Fort Worth TianjinBangalore Hyderabad Philadelphie Detroit Bandung Houston Miami Canton (Guangzhou) Atlanta Ahmadabad Belo Horizonte Pune San Diego − Tijuana Ibadan Xian Saint−Petersbourg Harbin Wuhan Shantou Chengdu Hangzhou Phoenix Kano Nanjing Medan − Saint−Petersburg Seattle Tampa Alegre Berlin Surabaya Porto Recife Minneapolis Salvador CuritibaKanpur Jinan 106.5 BrasiliaFortaleza CincinnatiCleveland Hambourg Francfort Surat Changchun Jaipur Lucknow Denver Shijiazhuang Saint−Louis Dalian Taiyuan Zibo Brownsville − McAllen − Matamoros − Reynosa Orlando Nagpur Patna Campinas Portland − Ciudad Juarez Qingdao Tangshan El Paso Guiyang Pittsburgh Kunming Sacramento Charlotte Belem Munich Stuttgart City Anshan Salt Lake Changsha Bénin Wuxi Zhengzhou Nanchang Palembang Goiânia San Antonio Indianapolis Kansas City Columbus Indore Las Vegas Mirat Harcourt Kaduna Jilin Lanzhou Port Niznij Novgorod Santos Pandang (Macassar) Manaus Oshogbo Raleigh VadodaraUjung Bhopal Cirebon −Xinyang Nashik Bhubaneswar Ludhiana Beach − Norfolk − Corée du Nord) Durham Agra ZhanjiangVirginia Austin Coimbatore Nashville Dandong−Sinuiju (Chine Vitoria Greensboro − Winston−SalemXuzhou Luoyang Yogyakarta VisakhapatnamUrumqi Nanning Semarang Tanjungkarang (Bandar Lampung)Fuzhou (Bénarès) Kochi Mannheim HuainanVaranasi Rajkot Novosibirsk BielefeldBaotou Aba Volgograd Onitsha Suzhou Hefei Qiqihar Denpasar Samara Handan Leipzig−Halle São Luis Louisville GrandAsansolRostov Madurai Datong Rapids Iekaterinburg Allahabad Bengbu Mataram Jacksonville Ningbo Greenville − Jamshedpur Memphis City Spartanburg Oklahoma Natal Surakarta Jabalpur Richmond Tcheliabinsk BirminghamWenzhou Nuremberg Tegal Dhanbad Maisuru Chemnitz−ZwickauRongcheng OgbomoshoAmritsar Brême Buffalo Maceio Aurangabad Hohhot Nouvelle−Orléans RochesterMaiduguri Daqing Zhangjiakou TeresinaVijayawada Saarbruck−Forbach Hanovre Albany (France)Omsk Abuja Bhilai AomenSholapur SaratovKazan BaodingSrinagar Dresde Pingxiang Thiruvananthapuram Benxi Pessoa Zhenjiang Xianyang 106 Chandigarh Ranchi Guwahati Fresno Krasnojarsk Joao Kozhikkod Knoxville Ufa Samarinda Malang Ilorin Tucson 100 100.5 101 101.5 102 Log Rank http://brenocon.com/blog/2009/05/zipfs-law-and-world-city-populations/
  • 5. What does it mean? Let p (x )dx be the fraction of cities with a population between x and x + dx If this histogram is a straight line on log − log scales, then ln p (x ) = −α ln x + c where α and c are constants Hence p (x ) = Cx −α where C = ec
  • 6. What does it mean? Let p (x )dx be the fraction of cities with a population between x and x + dx If this histogram is a straight line on log − log scales, then ln p (x ) = −α ln x + c where α and c are constants Hence p (x ) = Cx −α where C = ec Distributions of this form are said to follow a power law The constant α is called the exponent of the power law We typically don’t care about c.
  • 7. The power law distribution Name f (x ) Notes Power law x −α Pareto distribution Exponential e − λx 1 (ln x −µ)2 log-normal x exp(− 2σ 2 ) Power law x −α Zeta distribution Power law x −α x = 1, . . . , n, Zipf’s dist’ Γ (x ) Yule Γ (x + α ) Poisson λx /x !
  • 8. Alleged power-law phenomena The frequency of occurrence of unique words in the novel Moby Dick by Herman Melville The numbers of customers affected in electrical blackouts in the United States between 1984 and 2002 The number of links to web sites found in a 1997 web crawl of about 200 million web pages
  • 9. Alleged power-law phenomena The frequency of occurrence of unique words in the novel Moby Dick by Herman Melville The numbers of customers affected in electrical blackouts in the United States between 1984 and 2002 The number of links to web sites found in a 1997 web crawl of about 200 million web pages The number of hits on web pages The number of papers scientist write The number of citations received by papers Annual incomes Sales of books, music; in fact anything that can be sold
  • 10. Zipf plots Blackouts Fires Flares 100 10−2 10−4 10−6 10−8 1−P(x) Moby Dick Terrorism Web links 100 10−2 10−4 10−6 10−8 100 102 104 106 100 102 104 106 100 102 104 106 x
  • 12. The power law distribution The power-law distribution is p (x ) ∝ x − α where α, the scaling parameter, is a constant The scaling parameter typically lies in the range 2 < α < 3, although there are some occasional exceptions Typically, the entire process doesn’t obey a power law Instead, the power law applies only for values greater than some minimum xmin
  • 13. Power law: PDF & CDF α 1.50 1.75 2.00 2.25 2.50 For the continuous PL, the pdf is 1.5 PDF −α α−1 x 1.0 p (x ) = xmin xmin 0.5 where α > 1 and xmin > 0. 0.0 CDF The CDF is: 1.5 − α +1 1.0 x P (x ) = 1 − xmin 0.5 0.0 0.0 2.5 5.0 7.5 10.0 x
  • 14. Power law: PDF & CDF α For the discrete power law, the pmf is 1.50 1.75 2.00 2.25 2.50 PDF x −α 1.5 p (x ) = ζ (α, xmin ) 1.0 where 0.5 ∞ 0.0 ζ (α, xmin ) = ∑ (n + xmin )−α 1.5 CDF n =0 1.0 is the generalised zeta function 0.5 When xmin = 1, ζ (α, 1) is the standard zeta function 0.0 0.0 2.5 5.0 7.5 10.0 x
  • 15. Moments Moments: ∞ α−1 x m = E [X m ] = x m p (x ) = xm xmin α − 1 − m min Hence, when m ≥ α − 1, we have diverging moments
  • 16. Moments Moments: ∞ α−1 x m = E [X m ] = x m p (x ) = xm xmin α − 1 − m min Hence, when m ≥ α − 1, we have diverging moments So when α < 2, all moments are infinite α < 3, all second and higher-order moments are infinite α < 4, all third order and higher-order moments are infinite ....
  • 17. Distributional properties For any power law with exponent α > 1, the median is defined: x1/2 = 21/(α−1) xmin
  • 18. Distributional properties For any power law with exponent α > 1, the median is defined: x1/2 = 21/(α−1) xmin If we use power-law to model wealth distribution, then we might be interested in the fraction of wealth in the richer half: ∞ − α +2 x1 / 2 xp (x )dx x1/2 ∞ = = 2−(α−2)/(α−1) xp (x )dx xmin xmin provided α > 2, the integrals converge
  • 19. Distributional properties For any power law with exponent α > 1, the median is defined: x1/2 = 21/(α−1) xmin If we use power-law to model wealth distribution, then we might be interested in the fraction of wealth in the richer half: ∞ − α +2 x1 / 2 xp (x )dx x1/2 ∞ = = 2−(α−2)/(α−1) xp (x )dx xmin xmin provided α > 2, the integrals converge When the wealth distribution was modelled using a power-law, α was estimated to be 2.1, so 2−0.091 94% of the wealth is in the hands of the richer 50% of the population
  • 20. Top-heavy distribution & the 80/20 rule Pareto principle: aka 80/20 rule The law of the vital few, and the principle of factor sparsity states that, for many events, roughly 80% of the effects come from 20% of the causes
  • 21. Top-heavy distribution & the 80/20 rule Pareto principle: aka 80/20 rule The law of the vital few, and the principle of factor sparsity states that, for many events, roughly 80% of the effects come from 20% of the causes For example, the distribution of world GDP Population quantile Income Richest 20% 82.70% Second 20% 11.75% Third 20% 2.30% Fourth 20% 1.85% Poorest 20% 1.40% Other examples are: 80% of your profits come from 20% of your customers 80% of your complaints come from 20% of your customers 80% of your profits come from 20% of the time you spend
  • 22. Scale-free distributions The power law distribution is often referred to as a scale-free distribution A power law is the only distribution that is the same on regardless of the scale
  • 23. Scale-free distributions The power law distribution is often referred to as a scale-free distribution A power law is the only distribution that is the same on regardless of the scale For any b, we have p (bx ) = g (b )p (x ) That is, if we increase the scale by which we measure x by a factor of b, the shape of the distribution p (x ) is unchanged, except for a multiplicative constant The PL distribution is the only distribution with this property
  • 24. Random numbers For the continuous case, we can generate random numbers using the standard inversion method: x = xmin (1 − u )−1/(α−1) where U ∼ U (0, 1)
  • 25. Random numbers The discrete case is a bit more tricky Instead, we have to solve the CMF numerically by “doubling up” and a binary search
  • 26. Random numbers The discrete case is a bit more tricky Instead, we have to solve the CMF numerically by “doubling up” and a binary search So for a given u, we first bound the solution to the equation via: 1: x2 := xmin 2: repeat 3: x1 := x2 4: x2 := 2x1 5: until P (x2 ) < 1 − u Basically, the algorithm tests whether u ∈ [x , 2x ), starting with x = xmin Once we have the region we use a binary search
  • 27. Fitting power law distributions
  • 28. Fitting power law distributions Suppose we know xmin and wish to estimate the exponent α.
  • 29. Method 1 1 Bin your data: [xmin , xmin + x ), [xmin + x , xmin + 2 x) 2 Plot your data on a log-log plot 3 Use least squares to estimate α Bin size: 0.01 Bin size: 0.1 Bin size: 1.0 100 10−1 10−2 CDF 10−3 10−4 10−5 100 101 102 103 100 101 102 103 100 101 102 103 x You could also use logarithmic binning (which is better) or should I say not as bad?
  • 30. Method 2 Similar to method 1, but Don’t bin, just plot the data CDF Then use least squares to estimate α Using linear regression is a bad idea
  • 31. Method 2 Similar to method 1, but Don’t bin, just plot the data CDF Then use least squares to estimate α Using linear regression is a bad idea Error estimates are completely off It doesn’t even provide a good point estimate of α
  • 32. Method 2 Similar to method 1, but Don’t bin, just plot the data CDF Then use least squares to estimate α Using linear regression is a bad idea Error estimates are completely off It doesn’t even provide a good point estimate of α On the bright side you do get a good R 2 value
  • 33. Method 3: Log-Likelihood The log-likelihood isn’t that hard to derive Continuous: n xi (α|x , xmin ) = n log(α − 1) − n log(xmin ) − α ∑ log i =1 xmin Discrete: n (α|x , xmin ) = −n log[ζ (α, xmin )] − α ∑ log(xi ) i =1 xmin −1 n = −n log[ζ (α)] + n log ∑ xi − α ∑ log(xi ) i =1 i =1
  • 34. MLEs Maximising the log-likelihood gives −1 n xi ˆ α = 1+n ∑ ln xxmin i =1 An estimate of the associated error is α−1 σ= √ n
  • 35. MLEs Maximising the log-likelihood gives −1 n xi ˆ α = 1+n ∑ ln xxmin i =1 An estimate of the associated error is α−1 σ= √ n The discrete case is a bit more tricky and involves ignoring higher order terms, to get: −1 n xi ˆ α 1+n ∑ ln xxmin − 0.5 i =1
  • 36. Estimating xmin Recall that the power-law pdf is −α α−1 x p (x ) = xmin xmin where α > 1 and xmin > 0 xmin isn’t a parameter in the usual since - it’s a cut-off in the state space Typically power-laws are only present in the distributional tails. So how much of the data should we discard so our distribution fits a power-law?
  • 37. Estimating xmin : method 1 The most common way is just look at the log-log plot What could be easier! Blackouts Fires Flares 100 10−2 10−4 10−6 10−8 1−P(x) Moby Dick Terrorism Web links 100 10−2 10−4 10−6 10−8 100 102 104 106 100 102 104 106 100 102 104 106 x
  • 38. Estimating xmin : method 2 Use a "Bayesian approach" - the BIC: −2 + k ln n = −2 + xmin ln n Increasing xmin increases the number of parameters Only suitable for discrete distributions
  • 39. Estimating xmin : method 3 Minimise the distance between the data and the fitted model CDFs: D = max |S (x ) − P (x )| x ≥xmin where S (x ) is the CDF of the data and P (x ) is the theoretical CDF (the Kolmogorov-Smirnov statistic) Our estimate xmin is then the value of xmin that minimises D Use some form of bootstrapping to get a handle on uncertainty of xmin
  • 40. Mechanisms for generating PL distributions
  • 41. Word distributions Suppose we type randomly on a typewriter We hit the space bar with probability qs and a letter with probability ql If there are m letters in the alphabet, then ql = (1 − qs )/m http://activerain.com/
  • 42. Word distributions Suppose we type randomly on a typewriter We hit the space bar with probability qs and a letter with probability ql If there are m letters in the alphabet, then ql = (1 − qs )/m The distribution of word frequency has http://activerain.com/ the form p (x ) ∼ x −α
  • 43. Relationship between α value and Zipf’s principle of least effort. α value Examples in literature Least effort for α < 1.6 Advanced schizophrenia 1.6 ≤ α < 2 Military combat texts, Wikipedia, Web Annotator pages listed on the open directory project α=2 Single author texts Equal effort levels 2 < α ≤ 2.4 Multi author texts Audience α > 2.4 Fragmented discourse schizophrenia
  • 44. Random walks Suppose we have a 1d random walk At each unit of time, we move ±1 4 q q q q 2 q q q q q q q q q q q q Position 0 q q q q q q q q q q q q q q q q q −2 q q q q −4 0 10 20 30 Time
  • 45. Random walks Suppose we have a 1d random walk At each unit of time, we move ±1 4 q q q q 2 q q q q q q q q q q q q Position 0 q q q q q q q q q q q q q q q q q −2 q q q q −4 0 10 20 30 Time If we start at n = 0, what is the probability for the first return time at time t
  • 46. Random walks With a bit of algebra, we get: n (2n) f2n = (2n − 1)22n For large n, we get 2 f2n n (2n − 1)2 So as n → ∞, we get f2n ∼ n−3/2 So the distribution of return times follows a power law with exponent α = 3/2!
  • 47. Random walks With a bit of algebra, we get: n (2n) f2n = (2n − 1)22n For large n, we get 2 f2n n (2n − 1)2 So as n → ∞, we get f2n ∼ n−3/2 So the distribution of return times follows a power law with exponent α = 3/2! Tenuous link to phylogenetics
  • 48. Phase transitions and critical phenomena Suppose we have a simple lattice. Each square is coloured with probability p = 0.5 We can look at the clusters of coloured squares. For example, the mean cluster area, s , of a randomly chosen square: If a square is white, then zero If a square is coloured, but surround by white, then one etc
  • 49. Phase transitions and critical phenomena Suppose we have a simple lattice. Each square is coloured with probability p = 0.5 We can look at the clusters of coloured squares. For example, the mean cluster area, s , of a randomly chosen square: If a square is white, then zero If a square is coloured, but surround by white, then one etc When p is small, s is independent of the lattice size When p is large, s depends on the lattice size
  • 50. Phase transitions and critical phenomena p=0.3 As we increase p, the value of s also increases For some p, s starts to increase with the lattice size p=0.5927... This is know as the critical value, and is p = pc = 0.5927462.. If we calculate the distribution of p (s ), then when p = pc , p (s ) follows a power-law distribution p=0.9
  • 51. Forest fire This simple model has been used as a primitive model of forest fires We start with an empty lattice and trees grow at random Every so often, a forest fire strikes at random If the forest is too connected, i.e. large p, then the forest burns down So (it is argued) that the forest size oscillates around p = pc
  • 52. Forest fire This simple model has been used as a primitive model of forest fires We start with an empty lattice and trees grow at random Every so often, a forest fire strikes at random If the forest is too connected, i.e. large p, then the forest burns down So (it is argued) that the forest size oscillates around p = pc This is an example of self-organised criticality
  • 53. Future work There isn’t even an R package for power law estimation Writing this talk I have (more or less) written one Use a Bayesian change point model to estimate xmin in a vaguely sensible way RJMCMC to change between the power law and other heavy tailed distributions References A. Clauset, C.R. Shalizi, and M.E.J. Newman. Power-lawdistributionsinempiricaldata. http://arxiv.org/abs/0706.1062 MEJ Newman. Powerlaws,ParetodistributionsandZipf’slaw. http://arxiv.org/abs/cond-mat/0412004