Expand my Community achievements bar.

how do you display this number as a percentage rather than a number

Avatar

Level 1

i want to be able to display the % of how much this one product takes on from this add to cart origin? is this possible? 

ShariAn_0-1733226245044.png

 

2 Replies

Avatar

Community Advisor

HI @ShariAn 

not sure I can follow. What exactly do you need?

  • Which product do you mean with "this one product"?
  • Which value do you need as percentage?
Cheers from Switzerland!


Avatar

Community Advisor and Adobe Champion

If I'm understanding your question correctly, you want to know what percent of the add to carts came from each product?

If so, you can do this using the column sum function in a calculated metric. The column sum is a function that adds up all of the values for a particular column - so it will add all of the add to carts for all of the rows. Then you can take your metric divided by the column sum. I used orders in my example, but you can do this with cart additions to get an ATC rate. 

MandyGeorge_0-1733239761875.png

 

Once you have the metric created, you just add it as a column in your table. I added two examples, the one with the orders from above, and then I also did a cart addition one too. In the regular orders and cart addition columns you can see beside the main number there is a % in there. That is similar to what we just calculated. It shows what percent of the total is coming from each row. The difference between what that is doing and what we calculated is that our calculation doesn't take into account deduplication. You'll notice for cart adds, the small percent and what we calculated are basically the same for each row, that's because you only add one product to cart at a time. But for online orders, you can have more than one product in a particular order. But the metric deduplicates that in the total. The column sum metric ignores the deduplication and sums up all of the values for the calculation. So it will give you a slightly different number. 

If you were to add up all the rows in the table for orders, you would get a number greater than the total because of this deduplication, so using the column sum function instead of relying on the default % will give you a more accurate result.

MandyGeorge_2-1733239956342.png