rajsMad Scientists Daily
Updated 2023-03-14Copy Reference Fork
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
›
⌄
SELECT
date_trunc('day', block_timestamp) as date,
max(sales_amount) as highest_sale_price,
percentile_cont(0.5) within group (order by sales_amount) as median_sales_price,
avg(percentile_cont(0.5) within group (order by sales_amount)) over (order by date_trunc('day', block_timestamp) rows between 7 preceding and 1 preceding) as "prior_7_days_avg_median_sales_price",
min(sales_amount) as lowest_sale_price,
count(*) as no_of_sales,
avg(count(*)) over (order by date_trunc('day', block_timestamp) rows between 7 preceding and 1 preceding) as "prior_7_days_avg_no_of_sales",
sum(sales_amount) as volume,
avg(sum(sales_amount)) over (order by date_trunc('day', block_timestamp) rows between 7 preceding and 1 preceding) as "prior_7_days_avg_volume",
count(distinct seller) as no_of_unique_sellers,
count(distinct purchaser) as no_of_unique_purchasers,
sum(sales_amount) * 0.08 as royalty,
sum(sum(sales_amount)) over (order by date_trunc('day', block_timestamp)) as cumu_royalty
from solana.core.fact_nft_sales
where mint IN
(
SELECT
address
from solana.core.dim_labels
where address_name = 'communi3: mad scientists'
)
and block_timestamp >= CURRENT_DATE - interval '60 days'
group by 1
order by 1 desc
Run a query to Download Data