Current Python 3 examples have errors because print statements now require parentheses.
Please make the following corrections to the 'How to access the catalogue using Python' section:
Output mass and radius of all planets
for planet in oec.findall(".//planet"):
print([planet.findtext("mass"), planet.findtext("radius")])
Find all circumbinary planets
for planet in oec.findall(".//binary/planet"):
print(planet.findtext("name"))
Output distance to planetary system (in pc, if known) and number of planets in system
for system in oec.findall(".//system"):
print(system.findtext("distance"), len(system.findall(".//planet")))
Current Python 3 examples have errors because print statements now require parentheses. Please make the following corrections to the 'How to access the catalogue using Python' section:
Output mass and radius of all planets
for planet in oec.findall(".//planet"): print([planet.findtext("mass"), planet.findtext("radius")])
Find all circumbinary planets
for planet in oec.findall(".//binary/planet"): print(planet.findtext("name"))
Output distance to planetary system (in pc, if known) and number of planets in system
for system in oec.findall(".//system"): print(system.findtext("distance"), len(system.findall(".//planet")))