R/calculate_intensity.R: moved some of the statistical functions inside other function to avoid having to many functions

Signed-off-by: Charles Joly Beauparlant <Charles.Joly-Beauparlant@crchul.ulaval.ca>
R/calculate_intensity.R: cleaned the functionconvertReadsToPosVector and changed the name to convertReadsToDensity