> On Aug 18, 2019, at 9:20 AM, Senhaji Rhazi hamza 
> <hamza.senhajirh...@gmail.com> wrote:
> 
> Hey Steven, 
> 
> I think there is a way to map x <- [1; + inf] to y <- [0;1] by putting y = 1/x
> 

One big issue with using that mapping is it doesn’t preserve many of the 
characteristics of the initial distribution. If the x distribution is low 
waited, then the y distribution is high weighted.

If you want to try to preserve the shape, the fact that you are mapping a 
distribution that goes to infinity to a value with an upper limit says  it 
can’t be precisely done and maintain distribution.  You could shift it down by 
subtracting 1, possible scale it, and then truncate it if you get a value to 
large (either redraw or just saturate to 1). This will give you something with 
close to the right shape, depending on how you want to define a mapping of an 
infinite range to a finite range.
_______________________________________________
Python-ideas mailing list -- python-ideas@python.org
To unsubscribe send an email to python-ideas-le...@python.org
https://mail.python.org/mailman3/lists/python-ideas.python.org/
Message archived at 
https://mail.python.org/archives/list/python-ideas@python.org/message/KECLDYIPCGWR4A27HF5D2JTE2YKQ6M7N/
Code of Conduct: http://python.org/psf/codeofconduct/

Reply via email to