Concilio dei topini

Causality

Topino 106

Ho finito di leggere “Causality: Models, Reasoning, and Inference” di Pearl.

Se volete leggerlo badate di trovare la ristampa corretta (2013) o quantomeno la seconda edizione (2009), e di complementarla con gli errata che trovate sul sito di Pearl.

Un bel libro! Ha il difetto che non è sistematico. Ripete abbastanza volte le cose da fartele capire, però se poi ti viene un dubbio non sai bene dove andare a rileggere per levartelo. Non ci sono esercizi e le cose compaiono con un ordine un po’ fantasioso. È più un mucchio e un riassunto dei risultati della ricerca di Pearl che un trattamento ordinato. Per capire le cose in pratica ho dovuto inventarmi da solo degli esempi e ragionarci a lungo.

Ad esempio nel capitolo 3 introduce il do-operator nei Bayesian networks, per rappresentare le azioni, mentre bisogna aspettare fino al capitolo 7 per arrivare ai modelli strutturali semi-deterministici (gli SCM) per implementare i potential outcomes e definire i controfattuali. Però comunque nel capitolo 3 definisce gli SCM e i PO alla svelta senza dire bene cosa sta facendo e ne discute pure come se il lettore dovesse capirci qualcosa, menzionando che poi li spiegherà meglio nel capitolo 7. Nel capitolo 7 invece dice “come avevamo detto nel capitolo 3” e se hai capito bene se no ti arrangi. Io per fortuna avevo già letto “The Book of Why” quindi sapevo già tutti i concetti e sono riuscito a seguire, però mi immagino che uno studente che dovesse davvero usare questo libro per preparare un esame perderebbe un sacco di tempo.

Altro esempio: nel capitolo 10 cerca di formalizzare il concetto di “causa effettiva”, cioè come determinare se X ha causato Y in uno specifico avvenimento o contesto, in contrasto con l’influenza causale che X può avere in generale su Y. Cioè se sparo a qualcuno e muore, ma poi—colpo di scena!—scopro che era già stato ucciso da un dardo avvelenato lanciato da un indiano nascosto, non mi interessa che in generale se spari a qualcuno puoi causarne la morte, per essere linciato o no conta se è colpa mia e la colpa invece è dell’indiano. Negli esempi concreti di solito è facile giudicare a intuito quale sia la “causa effettiva” però dare una definizione rigorosa di quello che facciamo a mente senza pensarci non è banale. Pearl ci dedica un po’ di pagine ma alla fine riesce a tirare fuori una definizione e a far vedere che funziona bene in tanti esempi. Solo che alla fine del capitolo, nel “Postscript for the Second Edition”, dice:

Halpern and Pearl (2001a,b) discovered a need to refine the causal beam definition of Section 10.3.3. They retained the idea of defining actual causation by counterfactual dependency in a world perturbed by contingencies, but permitted a wider set of contingencies.

To see that the causal beam definition requires refinement, consider the following example.

[…]

A refinement that properly handles such counterexamples was proposed in Halpern and Pearl (2001a,b) but, unfortunately, Hopkins and Pearl (2002) showed that the constraints on the contingencies were too liberal. This led to a further refinement (Halpern and Pearl 2005a,b) and to the definition given below:

[…]

Halpern and Hitchcock (2010) summarize the state of the art of the structural approach to actual causation, and discuss its sensitivity to choice of variables.

Il “refinement” sarebbe che la definizione originale in realtà funzionava solo per variabili binarie. Mi viene in mente una discussione di Pearl con Gelman, in cui Gelman dice

Reading Pearl’s article, however, reminded me of another distinction, this time between discrete models and continuous models. I have a taste for continuity and always like setting up my model with smooth parameters. I’m just about never interested in testing whether a parameter equals zero; instead, I’d rather infer about the parameter in a continuous space. To me, this makes particular sense in the sorts of social and environmental statistics problems where I work. For example, is there an interaction between income, religion, and state of residence in predicting one’s attitude toward school vouchers? Yes. I knew this ahead of time. Nothing is zero, everything matters to some extent. As discussed in chapter 6 of Bayesian Data Analysis, I prefer continuous model expansion to discrete model averaging.

E Pearl risponde

The difference between “discrete” and “fully continuous”
is tangential. No matter how continuous you are, to
express a qualitative fact like “seat-belt does not
cause cancer” you become discrete, or discrete in disguise.
And this is precisely the meaning of the missing arrows in the
causal graphs: qualitative statement about lack of
influence”.

Tiè Pearl, prima o poi dovevi sbattere il grugno a forza di fare solo gli esempi con le variabili binarie! Vabbé, comunque ha corretto il suo errore, no? Però andando a rileggere la sezione 10.3.3 in cui dà la prima definizione (sbagliata)—ok no in realtà non è la sezione 10.3.3, bensì la definizione 10.3.3 che sta da un’altra parte, mannaggia a Pearl—non menziona da nessuna parte che è errata. Ma porca miseria! Uno che sta cercando un’informazione non può permettersi di leggere tutto un libro di 400 pagine in fila per essere sicuro di non aver letto cose sbagliate!

Ulteriore esempio che ricordo: nel capitolo 7, sezione 7.1.4, “The Twin Network Method”, spiega come ricavare in pratica le relazioni di indipendenza condizionale tra i potential outcomes a partire dalle assunzioni causali. Tutto bellino. Alla fine della sezione scrive:

Additional considerations involving twin networks, including generalizations to multi-networks (representing counterfactuals under different anticedants) are reported in Shpitser and Pearl (2007). See Sections 11.3.2 and 11.7.3.

Cosa dirà nelle sezioni 11.3.2 e 11.7.3? Qualche informazione di fondamentale importanza? Andiamo a vedere.

11.3.2 Demystifying “Strong Ignorability”

Researchers working within the confines of the potential-outcome language express the condition of “zero bias” or “no-confounding” using an independence relationship called “strong ignorability” (Rosenbaum and Rubin 1983). Formally, if X is a binary treatment (or action), strong ignorability is written as:

[…]

E così via, spiega come ricavare l’ignorabilità forte dai grafi, dicendo che Rubin è “confinato” e le solite cose che dice su Rubin. Quindi fin qui niente sorprese. Ma io sono meticoloso e voglio controllare anche la sezione 11.7.3.

11.7.3 d-Separation of Counterfactuals

Question to Author:

I am trying to generalize the twin network procedure of Figure 7.3 to cases where the counterfactuals involve more than two possible worlds. Consider the causal model $X\to Z\to Y$, and assume we wish to test the assertion $$\newcommand{\Perp}{\mathrel{\rlap{\perp}\mkern1mu\perp}} Y_x \Perp X \mid Y_z, Z_x, Y \tag{11.40} $$ is true in the model. I would naively construct the following “triple network”:

Figura 11.18 pag. 394 di Causality, seconda edizione

The left part corresponds to a world in which no intervention is imposed; the middle part to a world in which $do(X=x)$ is imposed; and in the right part, $do(Z=z)$ is imposed. In this network (11.40) does not follow from d-separation, since the path from $Y_x$ to $X$ is open by conditioning on $Y$. Is there anything wrong with this way of generalizing the twin network method?

Sì sì tranquillo funziona:

Author’s Reply (with Ilya Shpitser):

Your generalization of the twin network to more than two worlds is correct, and so is your conclusion; $Y_x$ is not independent of $X$ given $Y_z$, $Z_x$, $Y$. In fact, a recent paper (Shpitser and Pearl 2007) formulates this graphical representation of counterfactuals in multiple worlds under the rubric “counterfactual graphs”.

Ma siete proprio sicuri?

Follow-up Question to Author:

Your answer helped me understand the twin network method, as well as the one used in the paper “Direct and Indirect Effects” (Pearl 2001c), but it raises a new question: why does $Y_{xz} \Perp Z_{x*} \mid W$ hold in the graph of Figure 11.19, as claimed in (Pearl 2001)? If one draws a “triple network,” it is obvious that the path between $Y_{xz}$ and $Z_{x*}$ is not blocked by $W$; the latter is situated in a totally different world.

Figura 11.19 pag. 394

Ahah no scherzavo:

Author’s Second Reply:

The independence $Y_{xz} \Perp Z_{x*} \mid W$ actually holds in the graph shown in Figure 11.19.

This is because $Y_{xz}$ is separated from $Z_{x*}$ by the variable $W_{x*}$, in the “triple network” that you metioned. The license to replace $W$ with $W_{x*}$ is obtained from rule 3 of do-calculus, which implies $W_{x*} = W$, since $X$ is a nondescendant of $X$. This points to an important refinement [aridaje coi refinements!] needed in the twin network generalization: causal axioms may entail certain equality constraints among seemingly distinct counterfactual variables, and these hidden equalities need to be considered when we apply d-separation to counterfactual networks. A systematic way of encoding and managing these equalities is presented in Shpitser and Pearl (2007).

Sì, va bene, in base ai teoremi enunciati nel capitolo 1 la d-separazione è sufficiente ma non necessaria per l’indipendenza negli SCM perché alcune frecce rappresentano relazioni deterministiche e quindi la distribuzione di probabilità non è strettamente positiva. PERÒ DILLO NELLA CRISTO DI SEZIONE IN CUI SERVE. Non basta aggiungere un paragrafino in fondo con scritto “Toh magari leggiti le additional considerations in questo articolo”. Ho sentito dire che i metodi di Pearl non si sono diffusi abbastanza tra gli statistici sostanzialmente perché ha la dolcezza caratteriale di una raspa che ti gratta il culo, però adesso penso invece che sia per questioni pratiche di leggibilità come queste. Nel 2016 è uscito “Causal Inference in Statistics: A Primer” che è più introduttivo e ha gli esercizi, però mi sa che contiene solo una piccola parte dei risultati. Insomma non c’è ancora un testo che ti presenta tutto in ordine stile manuale di matematica.

Lascia un commento

Il tuo indirizzo email non sarà pubblicato. I campi obbligatori sono contrassegnati *

© 2024 Concilio dei topini Torna sù