add statistics.rb as require and files
add statistics functions