Datamule Statistics
Choose a statistic
Choose a statistic to view its charts.
When a SEC filings is accepted by the SEC, a Filing Metadata page is immediately created. Then, seconds, minutes, hours, or days later the filing is emitted on the RSS feed. Fastest SEC Filings Websocket uses a combination of RSS improvements and predictive algorithms to detect filings faster. Below are graphs comparing it to the normal websocket. The normal websocket should be as fast or faster than existing commercial options. The underlying data is from SEC Filings Metadata. More details on design: How to Make a Fast SEC Filing Detection System.
How much faster URL prediction is than RSS/EFTS
Getting SEC Filings faster than RSS through URL prediction
Fastest SEC Filings prediction algorithm 'index_url' vs Websocket's 'anticipate'
RSS speed improvement via better understanding of sec.gov load balancing
Source: Datamule public statistics data.
Code
Use datamule-hub to download the source data for the last 30 complete Eastern days.
from datetime import datetime, time, timedelta
from zoneinfo import ZoneInfo
from datamulehub import databases
eastern = ZoneInfo("America/New_York")
end_date = datetime.now(eastern).date()
start_date = end_date - timedelta(days=30)
start_seconds = int(datetime.combine(start_date, time(), eastern).timestamp())
end_seconds = int(datetime.combine(end_date, time(), eastern).timestamp())
databases.query(
f"""
SELECT accession, detected_time, detection_method
FROM fastest_sec_filings_metadata
WHERE detected_time >= {start_seconds * 1000}
AND detected_time < {end_seconds * 1000}
""",
output_dir="fastest",
)
databases.query(
f"""
SELECT accession, source, detected_time
FROM monitor_dumps
WHERE detected_time >= {start_seconds}
AND detected_time < {end_seconds}
AND lower(source) IN ('rss', 'efts', 'anticipate')
""",
output_dir="websocket",
)
databases.query(
f"""
SELECT accessionnumber, acceptancedatetime, filingdate
FROM submissions_metadata
WHERE filingdate >= '{start_date}'
AND filingdate < '{end_date}'
""",
output_dir="linked_filings",
)
SEC Filing Types
Loading filing types…
SEC filings by submission type
Source: Datamule filing types data.
Code
Use datamule-hub to download the filing type counts.
from datamulehub import databases
databases.query(
"""
SELECT
submissiontype,
CAST(date_trunc('week', CAST(filingdate AS DATE)) AS DATE) AS week_start,
year(CAST(filingdate AS DATE)) AS calendar_year,
COUNT(*) AS count,
SUM(CASE WHEN containsxbrl = 1 THEN 1 ELSE 0 END) AS xbrl_count
FROM sec_submission_details_table
WHERE submissiontype IS NOT NULL AND filingdate IS NOT NULL
GROUP BY 1, 2, 3
ORDER BY calendar_year, week_start, submissiontype
""",
output_dir="filing_types",
)