for an event i want to be able to see number of users for whom event frequency per user exceeds 10 within an hour. think comprehensively on how to do this and also how to change bucket size in distribution frequency
To see the number of users for whom the frequency of a specific event exceeds 10 within an hour, you have a few options in Mixpanel, depending on whether you want to use the UI (Insights report) or JQL (JavaScript Query Language).---
1. Using Insights Report (UI)
Frequency per User is a computed property in Mixpanel that allows you to segment or filter users by how many times they performed an event within a given interval (e.g., hour, day, week).
Steps:
1. Go to Insights.
2. Select your event.
3. For Measurement, choose Frequency per User.
4. Set the interval to hour.
5. Apply a filter or breakdown to show only users where frequency > 10.Distribution & Bucketing:
- By default, Mixpanel will bucket frequency values for you.
- To customize bucket sizes (e.g., to see users with frequency > 10), use the Custom Buckets option in the overflow menu.
- You can set even or varied buckets, or disable bucketing to see all values as-is. For your use case, you might set buckets like: <10
, 10-20
, 20+
, etc. This will allow you to easily see the count of users in each frequency range, including those exceeding 10 within an hour.> “Every numeric property is auto-bucketed into even-sized buckets by default without using custom buckets... Go to the overflow and open the custom buckets modal... choose Even or Varied Bucketing, or None for no bucketing.”
Custom Buckets: Numeric Property Use Cases---
2. Using JQL (Advanced)
If you need more control, you can use JQL to group by user and hour, count event frequency, and then filter for users with frequency > 10.Example JQL (pseudocode): LBKSfunction main() { return Events({ from_date: "2024-06-01", to_date: "2024-06-02" }) .groupByUser([function(event) { // Bucket by hour var date = new Date(event.time); return date.toISOString().slice(0, 13); // YYYY-MM-DDTHH }], function(count, events) { return (count || 0) + events.length; }) .filter(function(item) { return item.value > 10; }); }LBKS
This will give you the number of users (per hour) where the event frequency exceeds 10.For bucketing in JQL, you can use mixpanel.numeric_bucket()
to define custom bucket sizes for your frequency distribution: LBKS.groupBy([ mixpanel.numeric_bucket('value', {bucket_size: 10, offset: 1}) ], mixpanel.reducer.count())LBKS
This will bucket your frequency counts into intervals of 10 (e.g., 1-10, 11-20, etc.)
See: mixpanel.numeric_bucket()---
Summary
- UI: Use Frequency per User in Insights, set interval to hour, and use custom buckets to see users with frequency > 10.
- JQL: Group by user and hour, count events, filter for count > 10, and use mixpanel.numeric_bucket()
for custom bucket sizes.Let me know if you need a step-by-step for either method!
kapa.ai is still learning and improving, please let me know how I did by reacting below.
ℹ️ Tip: Mention @kapa.ai in the thread for follow-ups or DM the app for 1-to-1 help.
Hi Akshay J., Please stand by as I search the Mixpanel knowledge base for an AI-powered answer. I normally take about 15 seconds or so. In case AI cannot answer your question, feel free to reach out to Mixpanel support at mixpanel.com/get-support. If you have follow-up questions for this thread, please tag me again with your question: @kapa.ai <follow-up question> 👋
Feel free to ask a follow-up question once I've answered by mentioning me with @kapa.ai