0xHaM-dNew vs Recurring Users
    Updated 2024-12-05
    with txsTb as (
    SELECT
    BLOCK_TIMESTAMP,
    TX_HASH,
    sender as user
    FROM aptos.core.fact_events a
    JOIN aptos.core.fact_transactions b using(BLOCK_TIMESTAMP,TX_HASH)
    WHERE EVENT_ADDRESS = '0x9770fa9c725cbd97eb50b2be5f7416efdfd1f1554beb0750d4dae4c64e860da3'
    AND EVENT_MODULE = 'controller'
    AND EVENT_RESOURCE ilike ANY ('DepositEvent%','EndFlashLoanEvent%','WithdrawEvent%','BeginFlashLoanEvent%','ClaimRewardEvent%','LiquidateEven%')
    AND TX_TYPE = 'user_transaction'
    )
    ,DAU_u as (
    SELECT
    date_trunc('week', BLOCK_TIMESTAMP) as date,
    count(DISTINCT TX_HASH) as n_txs,
    count(DISTINCT user) as Active_users
    FROM txsTb
    GROUP BY 1
    )
    ,new as (
    SELECT
    date_trunc('week', first_tx) as date,
    count(DISTINCT user) as new_user
    FROM (
    SELECT
    user,
    min(block_timestamp) as first_tx
    FROM txsTb
    GROUP BY 1
    )
    GROUP BY 1
    )

    SELECT
    a.date,
    Last run: 13 days ago
    DATE
    N_TXS
    ACTIVE_USERS
    N_NEW_USER
    CUM_USERS
    RECURRING_USER
    NEW_USER_PERCENT
    RECURRING_USER_PERCENT
    Avg AU
    Avg New User
    CUM_N_TXS
    CUM_NEW_USER
    1
    2025-04-14 00:00:00.0001785850386954228124.47058895.52941215581.7510226.7941182942635695422
    2
    2025-04-07 00:00:00.00012801457319369538443804.22042495.77957615801.62686610378.8656722940850695384
    3
    2025-03-31 00:00:00.00012196482314069519146832.90275897.09724215971.75757610533.196972928049695191
    4
    2025-03-24 00:00:00.00031291913285169505182819.31887990.68112116143.27692310693.0923082915853695051
    5
    2025-03-17 00:00:00.000622044628484694200414410.45808189.54191916252.82812510846.8752884562694200
    6
    2025-03-10 00:00:00.00012200484927569371645745.67127294.32872816437.34920611011.3650792822358693716
    7
    2025-03-03 00:00:00.000776432520217278693441792468.55805131.44194916624.25806511184.5322582810158693441
    8
    2025-02-24 00:00:00.0004423997692453676163731625.11004274.88995816483.63934411084.6393442732515676163
    9
    2025-02-17 00:00:00.0001989038401164673710267630.312569.687516595.5511228.52688276673710
    10
    2025-02-10 00:00:00.00044584115549484672546207082.08412717.91587316811.74576311399.0847462668386672546
    11
    2025-02-03 00:00:00.000437283034432663062260214.23862985.76137116902.39655211432.1034482623802663062
    12
    2025-01-27 00:00:00.00040743278521366263025727.64811592.35188517145.70175411625.0877192580074662630
    13
    2025-01-20 00:00:00.00038428577444266241753327.65500592.34499517402.14285711828.8752539331662417
    14
    2025-01-13 00:00:00.0003614057922664661975312845.99447554.00552517613.56363612035.9090912500903661975
    15
    2025-01-06 00:00:00.000148993094548659311254617.711782.288317832.48148112209.4629632464763659311
    16
    2024-12-30 00:00:00.00093213000514658763248617.13333382.86666718110.56603812429.4905662449864658763
    17
    2024-12-23 00:00:00.000118783779619658249316016.37999583.62000518401.15384612658.6346152440543658249
    18
    2024-12-16 00:00:00.000287647727825657630690210.67684789.32315318687.86274512894.7058822428665657630
    19
    2024-12-09 00:00:00.000739512095115611656805534074.51195625.48804418907.0813136.12399901656805
    20
    2024-12-02 00:00:00.000241737916956641194696012.07680687.92319418865.36734713085.5918372325950641194
    68
    8KB
    157s