Add more detailed comments to the function for estimating PSD