%( op_m=1 maternal gr_parents & uncles, parents & siblings, paternal gr_parents & uncles in 3 columns %) %( op_m=2 maternal gr_parents & uncles, paternal gr_parents & uncles in 2 columns %) %let;op_m;%if;(op_m!="")%op_m;%else;1%end;%in; %let;bi;%index;%in; %if;(op_m=1 and has_parents) %if;(not (father.has_parents and mother.has_parents)) %if;father.has_parents;

[*paternal grand-parents], [uncles and aunts]1

%elseif;mother.has_parents;

[*maternal grand-parents], [uncles and aunts]1

%end; %end; %if;father.has_parents; %end; %if;(not mother.has_parents) %end;
%if;mother.has_parents;

[*paternal grand-parents], [uncles and aunts]1

%end;
    %apply;descendancy_grand_fathers("father","parhigh", bi) %apply;descendancy_grand_mothers("father","parhigh", bi)
%if;mother.has_parents; %if;father.has_parents;

[*maternal grand-parents], [uncles and aunts]1

%end;
    %apply;descendancy_grand_fathers("mother","parhigh", bi) %apply;descendancy_grand_mothers("mother","parhigh", bi)
%end;
%elseif;(op_m=2 and has_parents and (father.has_parents or mother.has_parents))
%if;father.has_parents;

[*paternal grand-parents], [uncles and aunts]1

%end;
%if;(has_parents and has_siblings)

[*parents], [full siblings]

%end;
%if;mother.has_parents;

[*maternal grand-parents], [uncles and aunts]1

%end;
%end;