grf
grf copied to clipboard
Further question for expression (14) in the Cui et al. (2020)
My name is Youngjoo Cho, who uses GRF package version 2.0.2. I asked at the causal_survival_forest.R and its reference "Estimating heterogeneous treatment effects with right-censored data via causal survival forests (Cui et al. 2020)". For expression (14) in the paper (see attached), you said to look at CausalSurvivalSplittingRule.cpp, and I found
for (size_t sample : samples) { double sample_weight = data.get_weight(sample); numerator_sum += sample_weight * data.get_causal_survival_numerator(sample); denominator_sum += sample_weight * data.get_causal_survival_denominator(sample); sum_weight += sample_weight; }
if (equal_doubles(denominator_sum, 0.0, 1.0e-10) || std::abs(sum_weight) <= 1e-16) { return true; }
double eta = numerator_sum / denominator_sum;
// Create the new outcomes. for (size_t sample : samples) { double response = (data.get_causal_survival_numerator(sample) - data.get_causal_survival_denominator(sample) * eta) / denominator_sum; responses_by_sample(sample, 0) = response; } return false; }
However, I am still not sure why
double eta = numerator_sum / denominator_sum;
// Create the new outcomes. for (size_t sample : samples) { double response = (data.get_causal_survival_numerator(sample) - data.get_causal_survival_denominator(sample) * eta) / denominator_sum; responses_by_sample(sample, 0) = response; } return false; }
is equal to expression (14). Could you explain this?
Sincerely,
Youngjoo Cho cui_et_al_2020.pdf
Ref the comment in #1154 (11) solved for tau (the name "eta" is used in the code) is composed of a numerator and denominator. The term (data.get_causal_survival_numerator(sample) - data.get_causal_survival_denominator(sample) * eta) is the score psi for observation i using this construction. 1/denominator_sum; is the 2nd term (W_j - e(X_j)^-2 .The third term is 1 in expectation and ignored (see e.g Tsiatis, 2007)
Looking at this again I realize naming conventions in the code could be improved to be in sync with the paper, I'll update it.