Begin Unverified Perl with AIC

Here is what I want to do...

I have a list called S8 - Items in this list are

String Cheese
Sausage
Cheese
Shredded Cheese
Tortilla
Singles
None

In S8, it asks, which of the following do you buy? I only show the list from 2 through 7 (multiple choice)

If they select Cheese, they are asked S9 -What is your likelihood to buy string cheese... They rate this from 5,4,3,2,1 - If they rate a 5 or 4, they are considered a String Cheese buyer

So, I now need to bring these answers forward into the question called Invite. I've created a new list called NewList

I only want to bring forward the choices in S8 of Cheese (position 3), Shredded Cheese (position 4) and Singles (position 6) if they select them, BUT also bring forward String Cheese (from the 1st position in S8List) if they rated S9 a 4 or a 5.

I'm struggling with this because the S9 question is ONLY asked if the respondent selects Cheese - if they don't, they skip S9. How do I do this? I'm using the AIC format plus perl. It's currently pulling in String Cheese into the Invite question if the respondent is not asked, I somehow have to factor out the null response…

Here is what I have thus far...

AIC (S8)

Begin Unverified Perl
if (VALUE("S9") <= 2) {ADD("S8List", 1);}
End Unverified

Randomize (2, 6)
REMOVE (S8List, 2)
REMOVE (S8List, 5)

Sort of confusing - let me know if you need more info.

Resolved
1 reply