Calculations › Market Trends
Show the average daily crypto market price trend, last 90 days
The query
-- graph market-wide: average daily crypto market trend, last 90 days
SELECT to_timestamp(tp.datetime)::date AS date, AVG(tp.price) AS avg_price
FROM ticketprice tp JOIN ticketname tn ON tn.id = tp.ticketnameid
WHERE tn.tickettype = 'crypto_pair'
AND tp.datetime >= EXTRACT(EPOCH FROM (NOW() - INTERVAL '90 days'))::bigint
GROUP BY 1 ORDER BY 1;
Runs against Cryptobi's market tables — ticketname (symbols),
ticketprice (daily prices and volume) and symbolmetadata
(sector, exchange, market cap and other reference fields).
Current output
| Date | Avg price |
|---|---|
| 2026-07-03 | 3096.82 |
| 2026-07-04 | 3123.86 |
| 2026-07-05 | 3146.62 |
| 2026-07-06 | 3168.42 |
| 2026-07-07 | 3133.26 |
| 2026-07-08 | 3081.94 |
| 2026-07-09 | 3126.63 |
| 2026-07-10 | 3173.92 |
| 2026-07-11 | 3157.99 |
| 2026-07-12 | 3156.65 |
| 2026-07-13 | 3082.30 |
| 2026-07-14 | 3218.21 |
| 2026-07-15 | 3207.80 |
| 2026-07-16 | 3160.77 |
| 2026-07-17 | 3164.75 |
Live output, first 15 rows, refreshed periodically. Model estimates are trend projections from recent prices, not financial advice.
Run this on your own holdings, change it, or write your own in SQL or Python — then put it on a dashboard or have it emailed on a schedule. Free, no credit card.
Sign Up Free