Page 1 of 1

Skip issues in Occurrences

Posted: September 30th, 2022, 1:47 am
by sham
Hi Family.
This is the issue.
I have designed a roster containing 3 rows and a set of 6 questions and with a response structure;

ITEM TOTALMALE TOTALFEMALE MALE0 FEMALE0 MALE1 FEMALE1
1 Project1 1 0 1 0 0 0
2 Project2 0 0 skip skip skip skip///////// Correct
3 Project3 1 1 skip skip skip skip ////////Why skip?

NOTE: The item name were program in the logic as;
PROC ITEM
preproc
$(1) = "Project1";
$(2) = "Project1";
$(3) = "Project1";

I have programmed a logic such that if TOTALMALE and TOTALFEMALE = 0 or TOTALMALE + TOTALFEMALE= 0 then MALE0, FEMALE0,MALE1,FEMALE1 should not be asked. But I still see that under Occurrence3, the skip is not working/violated.
Below is how I went around it.

I declared 3 variables at GLOBAL to hold the summation of each occurrence like this;

PROC TOTALFEMALE
postproc

SumMenWomen1 = TOTALMALE (1)+TOTALFEMALE(1)
SumMenWomen2 = TOTALMALE (2)+TOTALFEMALE(2)
SumMenWomen3 = TOTALMALE (3)+TOTALFEMALE(3)

IF SumMenWomen1= 0 then
skip to next;
endif;
IF SumMenWomen2= 0 then
skip to next;
endif;
IF SumMenWomen3= 0 then
endgroup;
endif;

I am still having challenges with that.
Please help me out.

Thank you.

Re: Skip issues in Occurrences

Posted: September 30th, 2022, 5:55 am
by etuser
Please try the the following, it might work

PROC TOTALFEMALE

postproc

If (TOTALMALE +TOTALFEMALE) =0 then skip to next; Endif; //without any subscript

Re: Skip issues in Occurrences

Posted: October 1st, 2022, 9:28 pm
by sham
Hi etuser,
Thank you soo much.
It works.

Thank very much.