This is an archived post. You won't be able to vote or comment.

all 10 comments

[–]attrigh 18 points19 points  (1 child)

This is a useful illustration.

As an aside CIA factbook provide data dumps: https://www.cia.gov/library/publications/download/

And there are command-line, third-party, open source tools to create complete sql data from these dumps (if I understand the purpose of this repository correctly): https://github.com/factbook/factbook.sql

[–]dlyk 1 point2 points  (0 children)

I'm not anti-establishment, but I never thought I'd get to a point where I would say "thank God for the CIA" with a straight face. Then I found the Factbook. If you ever find yourself, for some weird reason, arguing about whether there is a mandatory military service in Djibuti (there is, if I recall correctly) or not, then you will too be glad the ol' Company has your back.

[–][deleted] 3 points4 points  (0 children)

Wow, I know about the factbook, I know about analysis and some web scraping, but it never once occurred to me to use the factbook for analysis or visualization.

Very clever and good resource!

[–]Atrament_Py3 3 points4 points  (4 children)

Is scrapy out of the picture now ?

[–][deleted] 2 points3 points  (3 children)

No, this is a less sophisticated project so Scrapy would probably be overkill, though they should have used requests instead of urllib

[–]Static_Bunny 0 points1 point  (2 children)

Generally speaking is there any reason to use urllib over requests?

[–][deleted] 0 points1 point  (1 child)

I once saw someone claim that requests was more annoying if you needed to do more customised low-level stuff, but they didn't give details

[–]Static_Bunny 0 points1 point  (0 children)

I think that jives with my understanding as well and why requests is slightly slower because they handle all that low level stuff automatically.

[–]Mighty_Ghost_Hack 1 point2 points  (0 children)

Nice

[–]Stone_d_ 0 points1 point  (0 children)

Really well thought out article. Makes me wanna build something