Nothing
dag.letter2<-
function(dag, letter, alt.symb) ####
{ # function to draw the letters in the DAG;
# alt.symb is new since v1.1.2;
# dag.letter2: based on dag.letter, but returning a string and marking
# adjusted variables by a preceding underscore;
if(is.null(dag$symbols)) dag$symbols<-rep(NA, length(dag$x));
if(letter==1)
{ if( (alt.symb==FALSE) || (is.na(dag$symbols[1])) ) {
"X";
} else dag$symbols[1];
} else
if(letter==length(dag$x))
{ if( (alt.symb==FALSE) || (is.na(dag$symbols[letter])) ) {
"Y";
} else dag$symbols[letter];
} else
{
i_c<-0; # covariable counter for subscripts
i_u<-0; # unknown covs counter for...
for(i1 in 2:letter)
{
if(dag$names[i1]=="unknown" || dag$cov.types[i1]==2)
{ i_u<-i_u+1;
} else
{ i_c<-i_c+1;
}
}
if(dag$names[letter]=="unknown" || dag$cov.types[letter]==2)
{ if( (alt.symb==FALSE) || (is.na(dag$symbols[letter])) )
{ paste0("U", i_u);
} else
{ dag$symbols[letter];
}
} else
{ if(is.in(as.numeric(letter), dag$adj)==TRUE)
# the above use of as.numeric() was required due to some strange behaviour:
# without it, in some cases, this block would be skipped despite letter
# being in dag$adj; for instance with demo.dag2, if C1,3,5,7, or 9 was
# adjusted, they would not appear so in the write.paths() output, whereas
# both the manual use of dag.letter() and the coding for the nodes in dag.draw
# would produce the correct barred/underlined output. however, other DAGs,
# e.g. demo.dag1, were not affected!
{ if( (alt.symb==FALSE) || (is.na(dag$symbols[letter])) )
{ paste0("_C", i_c);
} else
{ paste0("_", dag$symbols[letter]);
}
} else
{ if( (alt.symb==FALSE) || (is.na(dag$symbols[letter])) )
{ paste0("C", i_c);
} else
{ dag$symbols[letter];
}
}
}
}
}
Any scripts or data that you put into this service are public.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.