Query editor
WITH data_source as (SELECT min(tx_timestamp_dt) as first_buy, to, count(to) as qtFROM reservoir.salesWHERE order_kind <> 'mint' AND wash_trading_score = 0--AND order_source!='blur.io' AND fill_source!='blur.io'--AND order_source!='looksrare.org' AND fill_source!='looksrare.org'GROUP BY toORDER BY 1)SELECT date, new_buyers, total_trades,SUM(new_buyers) OVER(ORDER BY date ROWS BETWEEN UNBOUNDED PRECEDING AND CURRENT ROW) AS cumulative_buyersFROM (SELECT DATE_TRUNC('week',first_buy) as date, count(to) as new_buyers, sum(qt) as total_tradesFROM data_sourceWHERE first_buy >= CURRENT_TIMESTAMP - INTERVAL '1000' day --AND qt>2GROUP BY 1)ORDER BY 1 DESC--New Buyers (3 or more NFTs)