官术网_书友最值得收藏!

  • Python Data Science Essentials
  • Alberto Boschetti Luca Massaron
  • 114字
  • 2021-08-13 15:19:34

Beautiful Soup

Beautiful Soup, a creation of Leonard Richardson, is a great tool to scrap out data from HTML and XML files that are retrieved from the internet. It works incredibly well, even in the case of tag soups (hence the name), which are collections of malformed, contradictory, and incorrect tags. After choosing your parser (the HTML parser included in Python's standard library works fine), thanks to Beautiful Soup, you can navigate through the objects in the page and extract text, tables, and any other information that you may find useful:

Note that the imported module is named bs4.
主站蜘蛛池模板: 邹城市| 喀喇| 沛县| 凤冈县| 滁州市| 响水县| 新巴尔虎右旗| 获嘉县| 华蓥市| 弥渡县| 泽普县| 马公市| 阿拉尔市| 临夏市| 吴忠市| 泾阳县| 湾仔区| 博湖县| 陕西省| 陕西省| 云浮市| 隆昌县| 山丹县| 习水县| 五大连池市| 襄汾县| 蕲春县| 榆中县| 中方县| 新巴尔虎右旗| 福州市| 肇庆市| 普格县| 宁安市| 宜兴市| 沙洋县| 武宣县| 新竹县| 余姚市| 定南县| 泰宁县|