6 Replies Latest reply on Jan 31, 2018 1:35 PM by Jim Dehner

# Average daily users over the past 90 days

To help track usage on our Tableau servers, we are trying to find the average amount of daily users over the past 90 days.  We don't work on weekends so I have Saturday and Sunday filtered out.  I'm also using a relative date filter to show the past 90 days (not sure if this takes into account no weekends as its showing Nov 3 through Jan 30).  Basically I have the distinct count of usernames who have used the tableau server on each day, I need to see the average over the past 90 days.  It needs to be one number, but I can't get distinct count to average by day over 90 days.

• ###### 1. Re: Average daily users over the past 90 days

Hi Wesley

Thanks,

Shin

• ###### 2. Re: Average daily users over the past 90 days

Hi I think I understand what you are saying -

the date 90 days (calendar days) ago is dateadd('day',-90,today())

so the 90 day period is        [your date] >= dateadd('day',-90,today()) and [your date]<= today()    - you can use that as a filter on the date set to True

then use        window_count(count(users id))  /  Window_count(countd([your date]))

that should do it - note I did not test so you may need to play with the syntax

Jim

If this posts assists in resolving the question, please mark it helpful or as the 'correct answer' if it resolves the question. This will help other users find the same answer/resolution.  Thank you.

• ###### 3. Re: Average daily users over the past 90 days

Thank you Jim for the response.  I understood the first step to get the 90 day window, but I'm struggling to understand the logic of step 2.  I made a calculated field using this formula, but what do I do with it? It keeps coming up as "1" for every day.

• ###### 4. Re: Average daily users over the past 90 days

Hi

you use it as a filter

here is the formula using superstore data

place it on the filter shelf

set to context

and set it to 1

the view is now limited to the lat 90 days

Jim

• ###### 5. Re: Average daily users over the past 90 days

Yes, I understood that step and it worked. I meant step 2 is still not working. When you referenced this formula: "window_count(count(users id))  /  Window_count(countd([your date]))".

I'm not sure what to do with that.  It is labeled in my screenshot as "Average Daily Users"

• ###### 6. Re: Average daily users over the past 90 days

Apologies the formula should be

WINDOW_SUM(count([Order ID]))/window_count(countd([Ship Date]))

wanted to sum the count of the individual days

JIm