dag.adjustment {dagR} | R Documentation |
Adjust a DAG for one or more variables.
Description
Identifies the associations introduced by adjustment for the
variables specified, and returns the DAG with these associations
added. Note that this is called internally by dag.adjust
, which
makes sure that biasing paths are looked for and evaluted afterwards.
Thus, dag.adjustment
should 1.) not be called directly, and
2.) not be called on an already adjusted DAG!
Usage
dag.adjustment(dag, A=NULL)
Arguments
dag |
The DAG to be adjusted. |
A |
The adjustment set to be applied. |
Details
The adjustment set A specified when calling dag.adjustment
overrules the
adjustment variables that are present in the DAG. To keep these in
the adjustment set, one has to add them to A.
Value
A DAG with A as the adjustment set and the associations introduced by adjustment for A added to the DAG.
Note
You should not use dag.adjustment
on an already adjusted
DAG, since it cannot identify associations that had been introduced
by the earlier adjustment. If the new adjustment set does not include
the adjustment variables present in the first set, the new DAG might
feature associations that actually only would be introduced when
adjusting for the variables featured in the first but not second
adjustment set.
Author(s)
Lutz P Breitling <l.breitling@posteo.de>
See Also
dag.adjust
, find.paths
,
eval.paths