You can try the $\arctan$ function which takes $\mathbb{R}$ to $(-\pi/2, \pi/2)$ and shift it accordingly: $$\frac 1\pi \arctan(x) + \frac 12$$
You can try the $\arctan$ function which takes $\mathbb{R}$ to $(-\pi/2, \pi/2)$ and shift it accordingly: $$\frac 1\pi \arctan(x) + \frac 12$$