Ref: https://github.com/pandas-dev/pandas-stubs/issues/438#issuecomment-1331403901
In DataFrameGroupBy.transform, the argument func can be a string as well as a Callable. This should be added to the docstring for the argument f (which should also be corrected to be func), and to the examples section. We already document this in the User Guide here.
Comment From: Dr-Irv
dup of #49961
Looks like the two issues created almost at the same time!
Comment From: rhshadrach
Hah, thanks!