st-tech / zr-obp

Open Bandit Pipeline: a python library for bandit algorithms and off-policy evaluation
Apache License 2.0
642 stars 87 forks source link

Missing parentheses in z-score calculation? #203

Open zhnhou opened 9 months ago

zhnhou commented 9 months ago

Noticed this line when enabling z-score calculation for expected rewards. Should it be

if z_score:
    expected_rewards = (
        ( expected_rewards - expected_rewards.mean() ) / expected_rewards.std()
    )

?

Fykqnt commented 4 months ago

@zhnhou Yes I agree.

https://github.com/st-tech/zr-obp/pull/201 https://github.com/st-tech/zr-obp/pull/201/commits/4455f129d5ebd3ef35dd6d78e11ba7ab17437556