I am trying to find the number of countries that have a certain type of industry.
Currently, I have this code:
countries = Flatten[CountryData[]]; listofCountries = Table[countries[[i]], {i, 1, 240}]; industries = Map[{CountryData[#, "MajorIndustries"]} &, CountryData[All]]; data = Table[industries[[i]] -> listofCountries[[i]], {i, 1, 240}]; I am not sure on how to find the number of countries that have an industry (i.e. Coal), or if I am headed in the correct direction.
Could somebody show me the correct way to find the number of countries with an industry?
EDIT: If I were trying to shade in the countries found on the world map with a color, how would I do so? (This is using the CountryData function.) I'm curious to see how much of the world has this industry, and so forth. (EDIT: How could I do it with the world map showing the boundaries of every country?)
EDIT 2: How could I do the edit above with two industries? (i.e. Coal and Copper)






