-
Notifications
You must be signed in to change notification settings - Fork 9
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
0 parents
commit 08a168c
Showing
23 changed files
with
5,637 additions
and
0 deletions.
There are no files selected for viewing
Empty file.
Large diffs are not rendered by default.
Oops, something went wrong.
Large diffs are not rendered by default.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
Sitemap: https://Elijas.github.io/sec-downloader/sitemap.xml |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,44 @@ | ||
[ | ||
{ | ||
"objectID": "index.html", | ||
"href": "index.html", | ||
"title": "sec-downloader", | ||
"section": "", | ||
"text": "Useful extensions for sec-edgar-downloader. Built with nbdev." | ||
}, | ||
{ | ||
"objectID": "index.html#install", | ||
"href": "index.html#install", | ||
"title": "sec-downloader", | ||
"section": "Install", | ||
"text": "Install\npip install sec_downloader" | ||
}, | ||
{ | ||
"objectID": "index.html#features", | ||
"href": "index.html#features", | ||
"title": "sec-downloader", | ||
"section": "Features", | ||
"text": "Features\n\nFiles are downloaded to a temporary folder, immediately read into memory, and then deleted.\nUse “glob” pattern to select which files are read to memory." | ||
}, | ||
{ | ||
"objectID": "index.html#how-to-use", | ||
"href": "index.html#how-to-use", | ||
"title": "sec-downloader", | ||
"section": "How to use", | ||
"text": "How to use\n\nDownload from ticker\nLet’s demonstrate how to download a single file (latest 10-Q filing details in HTML format) to memory.\n\nfrom sec_downloader import Downloader\n\ndl = Downloader(\"MyCompanyName\", \"[email protected]\")\nhtml = dl.get_latest_html(\"10-Q\", \"AAPL\")\n# Use dl.get_latest_n_html(\"10-Q\", \"AAPL\", n=5) to get the latest 5 10-Qs\nprint(f\"{html[:50]}...\")\n\n<?xml version=\"1.0\" ?><!--XBRL Document Created wi...\n\n\n\nNote The company name and email address are used to form a user-agent string that adheres to the SEC EDGAR’s fair access policy for programmatic downloading. Source\n\nWhich is implemented approximately as:\n\nfrom sec_edgar_downloader import Downloader as SecEdgarDownloader\nfrom sec_downloader import DownloadStorage\n\nONLY_HTML = \"**/*.htm*\"\n\nstorage = DownloadStorage(filter_pattern=ONLY_HTML)\nwith storage as path:\n dl = SecEdgarDownloader(\"MyCompanyName\", \"[email protected]\", path)\n dl.get(\"10-Q\", \"AAPL\", limit=1, download_details=True)\n# all files are now deleted and only stored in memory\n\ncontent = storage.get_file_contents()[0].content\nprint(f\"{content[:50]}...\")\n\n<?xml version=\"1.0\" ?><!--XBRL Document Created wi...\n\n\nDownloading multiple documents:\n\nstorage = DownloadStorage()\nwith storage as path:\n dl = SecEdgarDownloader(\"MyCompanyName\", \"[email protected]\", path)\n dl.get(\"10-K\", \"GOOG\", limit=2)\n# all files are now deleted and only stored in memory\n\nfor path, content in storage.get_file_contents():\n print(f\"Path: {path}\\nContent [len={len(content)}]: {content[:30]}...\\n\")\n\nPath: sec-edgar-filings/GOOG/10-K/0001652044-22-000019/full-submission.txt\nContent [len=15044932]: <SEC-DOCUMENT>0001652044-22-00...\n\nPath: sec-edgar-filings/GOOG/10-K/0001652044-23-000016/full-submission.txt\nContent [len=15264470]: <SEC-DOCUMENT>0001652044-23-00...\n\n\n\n\n\nDownload from Accession Number\n\ndl = Downloader(\"MyCompanyName\", \"[email protected]\")\nhtml = dl.get_primary_doc_html(accession_number=\"0000320193-23-000077\")\nprint(f\"{html[:50]}...\")\n\n<?xml version=\"1.0\" ?><!--XBRL Document Created wi..." | ||
}, | ||
{ | ||
"objectID": "index.html#contributing", | ||
"href": "index.html#contributing", | ||
"title": "sec-downloader", | ||
"section": "Contributing", | ||
"text": "Contributing\nFollow these steps to install the project locally for development:\n\nInstall the project with the command pip install -e \".[dev]\".\n\n\nNote We highly recommend using virtual environments for Python development. If you’d like to use virtual environments, follow these steps instead: - Create a virtual environment python3 -m venv .venv - Activate the virtual environment source .venv/bin/activate - Install the project with the command pip install -e \".[dev]\"" | ||
}, | ||
{ | ||
"objectID": "core.html", | ||
"href": "core.html", | ||
"title": "core", | ||
"section": "", | ||
"text": "source\n\nDownloadStorage\n\n DownloadStorage (filter_pattern:Optional[str]=None)\n\nInitialize self. See help(type(self)) for accurate signature.\n\nsource\n\n\nDownloader\n\n Downloader (company_name:str, email_address:str)\n\nInitialize self. See help(type(self)) for accurate signature." | ||
} | ||
] |
Large diffs are not rendered by default.
Oops, something went wrong.
Binary file not shown.
Large diffs are not rendered by default.
Oops, something went wrong.
Large diffs are not rendered by default.
Oops, something went wrong.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
Large diffs are not rendered by default.
Oops, something went wrong.
Oops, something went wrong.