cid-harvard / py-ecomplexity

Python package to compute economic complexity and associated variables
MIT License
63 stars 24 forks source link

PCI calculation. #19

Closed manapshymyr closed 3 years ago

manapshymyr commented 3 years ago

Dear team,

I was wondering about the PCI calculation. You have a equation:

 cdata.pci_t = (cdata.pci_t - cdata.eci_t.mean()) / cdata.eci_t.std()

cdata.eci_t = (cdata.eci_t - cdata.eci_t.mean()) / cdata.eci_t.std()

Shouldn't it be cdata.pci_t = (cdata.pci_t - cdata.pci_t.mean()) / cdata.pci_t.std() according to the https://growthlab.cid.harvard.edu/files/growthlab/files/atlas_2013_part1.pdf , page 24.?

shreyasgm commented 3 years ago

Refer https://github.com/cid-harvard/ecomplexity/issues/3

manapshymyr commented 3 years ago

Refer cid-harvard/ecomplexity#3

will this cdata.pci_t = (cdata.pci_t - cdata.pci_t.mean()) / cdata.pci_t.std() be correct for PCI calculation?

shreyasgm commented 3 years ago

The "correct" values are the ones the package outputs (with the ECI mean / std used for normalization). You can also work with the unnormalized indices themselves - the normalization is just a statistical treatment on top that lets us get the nice property described in the books and the link I sent above.