subtract two column pivot table using calculated value - excel

I need to find the average of profit by subtracting ( average budget from average revenue ) , both these two column calculated by pivot table
I tried to input this in the calculated field: =AVERAGE('Box Office Revenue ($)')-AVERAGE('Budget ($)')
and then summarized field value to Average but still show summation.
i don't need to subtract the summation of these two column but i need to subtract the averages.
Can you please support in that.

Related

Excel: Extracting data based on range

I have a table for the number of products sold:
I have another table that calculates the cumulative product sold
I have a price table based on # of product sold:
What equation should I write to get the cost price of the product based on cumulative data? Basically, as the cumulative product for category A is less than 10 till 2022 the multiplier price is $5 but in 2023 as the cumulative product is more than 10 the multiplier is $3.
Please know that the actual data set has a price multiplier for multiple range and the number of products sold is in million. The above is just a sample.
Lose the < character in the Item column of the price table. Then you can use it for an approximate lookup.
Let's say the price table is on a sheet called PriceSheet and starts in cell A1, so the first row of data is in row 2. The price table must be sorted ascending by the first column. To look up the price use
=vlookup(A1,PriceSheet!$A$2:$B$5,2,1)
Multiply that with the count.
=A1*vlookup(A1,PriceSheet!$A$2:$B$5,2,1)
Now just change A1 to the cell that has the cumulative count.

Calculated fields - sum of products

I tried to calculate a sum of a product (in the example: quantity product price), so If I sum all the products, I get a value (the dynamic table in the upper side). But when I enter the calculated field quantity*product, Excel got a sum of all the quantity product the sum of all the prices.
How can I solve that?
In this image, I have a table with the data that I want to show through a pivot table
If a put the column Total in the Value section, i get the sum of all the Total values, considering Total as a multiply of quantity and price
In this table, I put the calculate field quantity*price to get the sum, but I got the sum of quantity multiply the sum of price
The calculate field
It appears that you've done this:
But you should have done this:
To sum the individual months you can do this:
Or even this:

Pivot Table Sum Items, But Average Grand Total

I have a Standard Pivot Table it has Date from the Columns and Numbers in the Value,
Column: Date | Numbers
I want the Numbers in the Rows to be Calculated as Sum, but I want the Grand Total to Average those Sums Rows
How is this possible?
Assuming you have PowerPivot, which you should if you have 2016, and assuming a table called Table1 loaded into the data model, you can add a measure for the sum, called say TotalNumber, which is just:
=SUM(Table1[Numbers])
Then add another measure which is the one you'll use in the pivot table:
=IF(HASONEVALUE(Table1[Date]),[TotalNumber],averagex(VALUES(Table1[Date]),Table1[TotalNumber]))

Compare column value with series of auto sum value in Power Pivot?

I have problem where i need to get the number of weeks after which my stock will run-out.
In my table i have:
"Forecast Regulier calc." which is the total sales.
And the auto generated total is the project stock.
Each value of "Forecast Regulier calc." in column is the sales on that particular week. Now the goal is to compare the sales of each week with the series of all auto generated total values and get the difference in column values where the two values match. And this will be the number of weeks after which our stock will run-out.
Please let me know if the description is not clear.
.

Left outer join sum with DAX

I have 2 tables:
Fact sales table (sales)
Dimensional period table (dimperiod)
I have joined them through my model on the Period column. However, when I display the sales sum I got this.
I would like to have a row where no sales were made with a sum equal to 0. As below:
I've used the following DAX but didn't work.
CustomSales:=CALCULATE(SUM([Sales]), NATURALLEFTOUTERJOIN(sales,dimperiod))
Just change the pivot table to display blanks.
Or add 0 to your measure. Pivot tables do not display blanks by default. The first option above forces the pivot to display blanks, but you'd need to set this per pivot table. Addition implicitly coerces a blank to a numeric type.
SumSales:=
SUM( 'Sales'[Sales] ) + 0

Resources