14 Replies Latest reply on May 10, 2013 6:22 AM by Jonathan Drummey

# Grand Total Decimal - Error

Hi All,

I am not getting correct grand total with the ddecimal value as attached in the image.

Totals not correct.

Thanks

• ###### 1. Re: Grand Total Decimal - Error

How far off is it? Could it be a rounding error?

--Shawn

• ###### 2. Re: Grand Total Decimal - Error

CTR is a calculated field

sum([clic])/sum([mq])

 2/28/13 0.231459 0.23267 0.464129 3/1/13 0.228826 0.232263 0.461089 3/2/13 0.262174 0.265869 0.528043 3/3/13 0.260483 0.261372 0.521855 3/4/13 0.235647 0.240307 0.475954 3/5/13 0.231137 0.234896 0.466034 3/6/13 0.231824 0.231099 0.462923 3/7/13 0.225182 0.226845 0.452027 3/8/13 0.236818 0.232839 0.469657 3/9/13 0.248602 0.244008 0.49261 3/10/13 0.259279 0.249564 0.508843 Grand Total 2.65143 2.65173 5.30316

These are correct values

Values are not correct as seen in the image. Decimal numbers in use are rounded to 9 places

Thanks

• ###### 3. Re: Grand Total Decimal - Error

No, the values in Tableau are correct - the grand total is not a sum of all of the values, it's the calculation applied across all of the rows in the view.

• ###### 4. Re: Grand Total Decimal - Error

So how do I arrive at the summation values for rows and columns as shown in the image?

Thanks

• ###### 6. Re: Grand Total Decimal - Error

Hmm...not much i could understand from the link.

I want to show sum of rows and columns as in the image.

Thanks

• ###### 7. Re: Grand Total Decimal - Error

Hi, I wrote the blog post referred to in the linked message. What part don't you understand?

• ###### 8. Re: Grand Total Decimal - Error

Hi Jonathan,

I am trying to replicate the chart as pasted unable to understand how to add the rows and columns to get the last column and last row.totals

Thanks

• ###### 9. Re: Grand Total Decimal - Error

Ok, I can see where you might have gotten confused because you want to add up Grand Totals along both Rows and Columns.

In the attached, I used the Superstore Sales data to more clearly show the aggregations and desired re-aggregations. Order Date is the stand-in for Date, and Category the stand-in for Channel. I used Profit Ratio to show a field that is made up of two aggregates, SUM(Profit)/SUM(Sales). The Profit Ratio for Total calculation uses WINDOW_SUM([Profit Ratio]) to calculate the Profit Ratio within the detail rows, then to add it within the Grand Total row. There are duplicates of Order Date and Category on the Level of Detail Shelf, and table calculation has an Advanced Compute using of Category (copy) and Year of Order Date (Copy).

This uses the technique outlined in http://drawingwithnumbers.artisart.org/customizing-grand-totals-part-2/. If a webex works better, I also covered that in a Think Data Thursday session available at http://community.tableau.com/thread/125847, though this particular wrinkle of wanting the total in both directions at once I hadn't seen before so that isn't covered in that material.

Hope this helps!

Jonathan

• ###### 10. Re: Grand Total Decimal - Error

Excellent Thanks Jonathan

• ###### 11. Re: Grand Total Decimal - Error

Hi Jonathan,

How can I display a new column with "percentage change" based on the q1 and s1 columns that exists?

This column needs to be displayed next to the grand total column as PercentageChange.

Thanks

• ###### 12. Re: Grand Total Decimal - Error

What is the change compared to? Is the percentage across (q1 vs. s1) or down (q1 date to prior  q1 date)? And do you want a Grand Total computed for that or not?

This is where a mockup of your desired view would be helpful.

Cheers,

Jonathan

• ###### 13. Re: Grand Total Decimal - Error

Hi,

I may not need the grand total.

How can I show data for both percentage across (q1 vs. s1)

 c e % change 287326 302291 5.21% 279995 286302 2.25% 257758 259677 0.74% 282273 269791 -4.42%

Thanks

• ###### 14. Re: Grand Total Decimal - Error

I'm still not quite clear on what you want. I set something up in the attached using two worksheets and a dashboard. If that doesn't work for you, please provide a packaged workbook with some sample data and a mockup of what you want.