Efficience of profile script vs native functionnality | Community
Skip to main content
July 19, 2021
Solved

Efficience of profile script vs native functionnality

  • July 19, 2021
  • 1 reply
  • 1736 views

Hi!
I have got a case that not allow me to use an AB Test to split audience with 50/50.

 

Exp A (control) > 50%
Group B > 50%
(containing)
  Exp B (visitCount = 1)
  Exp C (visitCount = 2)
  Exp D (visitCount = 3)

 

To make it work, i have configured a XT activity using a profile script to split audience :


if (!user.get('twogroups')) {
var ran_number = Math.floor(Math.random() * 99);
if (ran_number <= 49) {
return 'ExpA';
} else {
return 'GroupB';
}
}

https://experienceleague.adobe.com/docs/target/using/audiences/visitor-profiles/use-profile-scripts-to-test-mutually-exclusive-activities.html?lang=en

Could you tell me if this method works as efficiently as the native split of an AB Test activity ?

This post is no longer active and is closed to new replies. Need help? Start a new post to ask your question.
Best answer by ryanr7

Hi @tienzen

Yes, that should split traffic into 2 groups as efficiently as the native splitter.

Extra tip: if you modify the profile script to simply return the random number between 1-100 you can then use the audience rule to split to groups of: 2, 4, 5, 10, etc. Your current profile script will only allow you to use 2 groups - so it's not potentially as useful to you in the long run that way.

1 reply

ryanr7Adobe EmployeeAccepted solution
Adobe Employee
July 20, 2021

Hi @tienzen

Yes, that should split traffic into 2 groups as efficiently as the native splitter.

Extra tip: if you modify the profile script to simply return the random number between 1-100 you can then use the audience rule to split to groups of: 2, 4, 5, 10, etc. Your current profile script will only allow you to use 2 groups - so it's not potentially as useful to you in the long run that way.

TienzenAuthor
July 21, 2021

[duplicate deleted]