2 Replies Latest reply on Oct 25, 2018 8:29 AM by adam jama

Am I calculating these averages correctly?

Hi,

I'm trying to figure out if Im calculating averages correctly.

The workbook below from tableau public has 3 averages.

1) average subtotal of each order per weekday.  ( i brought the pill to the viz and clicked on average to get that)

2) average spent per day by customers on a typical weekday. ( i created a calculated field: [average subtotal ]*[average order per day] )

3) average number of orders received per weekday. ( I created a calculated field: AVG({INCLUDE [Date] : COUNT([Number of Records])} )

Thanks in advance for your help. Especially number 2, if its correct is there a simpler way to calculate that ?

• 1. Re: Am I calculating these averages correctly?

It depends on what you are actually after, e.g. below are two orders, but there are two transaction type in different weekdays, both sub total will be involved in the calculation of avg for that weekday separately. While in order wise, the subtotal for the order should be 0 no matter which weekdays it is. So not sure which is your expected logic to calculate the average for this case.

ZZ

• 2. Re: Am I calculating these averages correctly?

Hi Zhouyi,

Thanks for taking the time to take a look at this.

You are correct any orders below zero is a refund so it shouldnt be considered in the averages.

What Im trying to get is the averages per day per weekday.