Let's say that we introduced a new feature called related items, on our e-commerce website, and we would like to know how this new feature affects our purchases.
This article is about creating a goal that would trigger when visitors click on the feature and revenue is generated. This compounded goal could tell us the influence of that click on purchases.
These would be the steps to take to create this compounded goal.
- So, first I would create a variation that would show that feature. We can do this by using the Visual Editor and adding also Custom JS to the new variation. I am not going to touch this into detail as this is not the goal of this article.
- Create two goals. One for the click on the new feature section, and another one for when revenue is generated on the page. Again, I am not going into detail on how to do this as it is not the goal of this article.
- Write down the goal id numbers located in each of your goal configurations in the goal editor.
- Open the Goal Editor and Click on the "Create Advanced Goal" tab.
- Click on the 'Page Tags" and drag the "JS Condition" item onto the main panel.
- Paste the following code into the 'JS Condition' text box, replacing the 'JS Code'. Making sure that you replace '1234' and '4567' with your own experiment ids, and name it. In this case, I am naming it 'New Feature Influence on Conversions'.
(1234 in convert.currentData.goals) AND (5678 in convert.currentData.goals)
- You are now done. Your goal should track when both the feature is clicked and a purchase is done. This should help you identify if this new feature is influencing the purchases.