Skip to main content

A Python package for parsing SEC data with XML and web scraping tools

Project description

sec_eagle

sec_eagle is a Python package for fetching and parsing SEC (Securities and Exchange Commission) filings. It leverages web scraping and XML parsing to help analysts and developers extract structured financial data.

🔍 Features

  • Fetch SEC filing data using Requests
  • Export data to Pandas DataFrames
  • Utilities for identifying key financial metrics
  • Any Inline Fact with a tag is scrapable

🚀 Installation

pip install sec_eagle


## 📦 Example Usage

```python
from sec_eagle import FileGather, SecCompany
import pandas as pd

# Initialize FileGather to search for filings
email = "your.email@example.com"
filings = FileGather(email=email, return_type="df")

# Specify the tickers and filing types
tickers = ["AAPL", "AMZN", "NFLX"]
filing_types = ["10-K", "10-Q", "20-F", "40-F"]
urls = filings.company_file(filing_types, tickers, "ticker")

# Tags to extract from XML filings
data_tags = ["dei:EntityCommonStockSharesOutstanding","dei:SecurityExchangeName"]  # example tags
data = []

# Loop through filings and collect parsed data
for url in urls:
    company = SecCompany(url=url, email=email, return_type="df")
    xml_data = company.xml_parser(data_tags)
    data.append(xml_data)

# Combine all company data into a single DataFrame
df = pd.concat(data).reset_index(drop=True)

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

sec_eagle-0.1.21.tar.gz (5.4 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

sec_eagle-0.1.21-py3-none-any.whl (5.6 kB view details)

Uploaded Python 3

File details

Details for the file sec_eagle-0.1.21.tar.gz.

File metadata

  • Download URL: sec_eagle-0.1.21.tar.gz
  • Upload date:
  • Size: 5.4 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.13.6

File hashes

Hashes for sec_eagle-0.1.21.tar.gz
Algorithm Hash digest
SHA256 c1fdad0c1f4261686b2e2a83e4dc5a8a1b8c7e70a61b9cb9e611827e9b837cb2
MD5 8882809a56c5d040c5b35fee4ef537df
BLAKE2b-256 251c2c097dbe099a046a6071c9b896ec3b9217d5cbb70e6b7183692973859e73

See more details on using hashes here.

File details

Details for the file sec_eagle-0.1.21-py3-none-any.whl.

File metadata

  • Download URL: sec_eagle-0.1.21-py3-none-any.whl
  • Upload date:
  • Size: 5.6 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.13.6

File hashes

Hashes for sec_eagle-0.1.21-py3-none-any.whl
Algorithm Hash digest
SHA256 68ca1a1834b355bf70b76fe777c57a17fbb474aa23d7a7c2a7e81b7429f48a11
MD5 63d0ce29040dfe91f282c243b8ca96b1
BLAKE2b-256 fb5c1f47496098313c267e75a5674f294207852705cc2ba81693b2b7120f7dd0

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page