Have an idea?

Visit Sawtooth Software Feedback to share your ideas on how we can improve our products.

automatically fill in "NA" for items in skip pattern

Is it possible to have the software automatically fill in "NA" when an item is skipped due to a skip patterns? Let me give an example to illustrate.

Question 1: No ---> Skip to Question 3
                        Yes ---> Continue to Question 2

Question 2: Yes
                         No

Question 3: Yes
                         No

If the respondent answers "No" in Question 1, the Question 2 is currently blank. Is it possible to automatically fill in "NA" (or another defined value like "999") in Question 2?
asked May 24 by wfung (275 points)

1 Answer

+1 vote
To achieve this, we'll want to use special script in our skip logic that sets values before running the skip.  Here's an example that skips when Q1 = 2 while setting Q2 to 999:

Begin Unverified Perl
my $shouldSkip = GETVALUE('Q1') == 2;
if ($shouldSkip) {
    SETVALUE('Q2', 999);
}
return $shouldSkip;
End Unverified
answered May 24 by Zachary Platinum Sawtooth Software, Inc. (212,750 points)
...