Skip to main content

py-html-table Package

This is a simple package which uses beautifulSoup to extract HTML Table data along which has rowspan.

Installation

pip install 'beautifulsoup4==4.5.3'
pip install py_html_table

Declare

import py_html_table

Parameters

Parameter Meaning Sample Values
table python variable containing html code of table any variable name
col Total No.of columns in the table. Starts from 1 5
begin No.of rows to begin scrapping. Starts from 0 2
output Type of output that you need list (or) dataframe (or) csv

NOTE: All variable names has to be provided as input to the package

Usage Example

import requests
from bs4 import BeautifulSoup
import requests_html
import lxml.html as lh
import py_html_table.py_html_table as pyht

url = 'https://en.wikipedia.org/wiki/List_of_Presidents_of_the_United_States'
session = requests_html.HTMLSession()
r = session.get(url)
content = BeautifulSoup(r.content, 'lxml')
all_tables = content.select(".wikitable")
table = all_tables[0]
col = 9
begin = 2
output = 'dataframe'
raw = 'N'
py_html_table.extract(table,begin,col,output,raw)

Metadata

Release files for py-html-table 0.0.4

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for py-html-table 0.0.4
File Size Uploaded Provenance Actions
py_html_table-0.0.4.tar.gz 2.7 kB Without provenance Details for py_html_table-0.0.4.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for py-html-table 0.0.4
File Interpreter ABI Platform Actions
py_html_table-0.0.4-py3-none-any.whl Python 3 none any Details for py_html_table-0.0.4-py3-none-any.whl

Total release size: 6.7 kB

Release files / py_html_table-0.0.4.tar.gz

Download URL py_html_table-0.0.4.tar.gz
Size 2.7 kB
Tags Source
SHA-256 checksum
How to use checksums
131ed241e7f90095ac2a7a2b703f85bda6bc4c7ce0d9010b864101c2d3c1654f
BLAKE2b-256 checksum
How to use checksums
771e55a9068c0fedef676b8888b23449c5315140cf1ebd93adf68f3dd7566aa9
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/1.12.1 pkginfo/1.4.2 requests/2.19.0 setuptools/40.6.2 requests-toolbelt/0.8.0 tqdm/4.28.1 CPython/3.6.5

Release files / py_html_table-0.0.4-py3-none-any.whl

Download URL py_html_table-0.0.4-py3-none-any.whl
Size 4.0 kB
Tags Python 3
SHA-256 checksum
How to use checksums
aef297086b4548ce54fe0caa56c3a0611b962c3b41136a6955abf1104029b47a
BLAKE2b-256 checksum
How to use checksums
cbcd7147000b21a6b6376e48b7bc58d3c7184b58e19f417cb8c9fe52ea4dafe6
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/1.12.1 pkginfo/1.4.2 requests/2.19.0 setuptools/40.6.2 requests-toolbelt/0.8.0 tqdm/4.28.1 CPython/3.6.5

Security for py-html-table 0.0.4

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page