Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Addition of "location" type parameter in the Gamma distribution #1805

Open
ikrommyd opened this issue Apr 5, 2024 · 2 comments
Open

Addition of "location" type parameter in the Gamma distribution #1805

ikrommyd opened this issue Apr 5, 2024 · 2 comments

Comments

@ikrommyd
Copy link

ikrommyd commented Apr 5, 2024

Adding a loc type parameter to the Gamma distribution like scipy has would be beneficial.
It is relatively common in physcs for people to use the Gamma distribution and data shifts are always important in such things.
@jonas-eschle

@SiegeLordEx
Copy link
Member

You can use the TransformedDistribution to apply these transformations in the meantime (and were this to ever be added, this is how we'd implement it):

shifted_scaled_gamma = tfd.TransformedDistribution(tfd.Gamma(...), [tfb.Shift(loc), tfb.Scale(scale)])

@ikrommyd
Copy link
Author

ikrommyd commented Apr 5, 2024

Thanks a lot for the suggestion. Great concept!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants