difficult to copy-paste from pictures
from the docstring
proportions for the first case will be computing using p2 and diff p1 = p2 + diff
so you need negative diff in your example
power_proportions_2indep(-0.1, 0.2, nobs1=300, ratio=1, alpha=0.05)
<class 'statsmodels.tools.testing.Holder'>
power = 0.9311797595418433
p_pooled = 0.15000000000000002
std_null = 0.5049752469181039
std_alt = 0.5
nobs1 = 300
nobs2 = 300
nobs_ratio = 1
alpha = 0.05
The basic idea behind normal_power_het is that the variance is different between null and alternative hypothesis.
In the standard t-test, we assume that variance is the same for all mean parameters.
Proportions and poisson rates have inherent heteroscedasticity, variance depends on the mean or expected value.
Because the latter differ between null and alternative, the standard deviation of the effect will also differ.
In this case, the (absolute) diff is the same in your case and the R case, but evaluated at different proportions, the std can have a large difference.
Josef