Updated g and f functions to take parameters

Also cleaned up estimates for mu,sigma, initial CCPs
Merge pull request #8 from CY-Chan/master

Updated g and f functions to take parameters