greyswanNFT users cohorts_volumes
Updated 2023-03-14
99
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
›
⌄
-- forked from b4cf3a4a-0824-4fba-8b28-dacfb8828f0f
with
unique_NFT_users as (
select
date_trunc('month', block_timestamp) as NFT_month,
count(tx_id) as buy_volume,
purchaser
from
solana.core.fact_nft_sales
where
block_timestamp >= '2022-03-01'
and block_timestamp <= '2023-02-28'
group by
purchaser,
NFT_month
),
NFTs_with_cohorts as (
select
NFT_month,
purchaser,
signer,
date_trunc('month', FIRST_TX_DATE) as cohort_month,
buy_volume
from
unique_NFT_users
left join solana.core.ez_signers on purchaser = signer
)
select
NFT_month,
cohort_month,
avg(buy_volume),
median(buy_volume)
from
NFTs_with_cohorts
group by
NFT_month,
Run a query to Download Data