title: How to implement histfit in r?
body: <p>There is histfit function in Matlab would plot histogram and fit the distribution by bin values.
  The distribution's parameters have to be estimated.
  How to implement histfit in r? I searched for a long time, but it has no lucky.</p>
  
  <p>This <a href="https://stackoverflow.com/questions/1497539">post</a> have mentioned this before, but there is no preferable solution. The sn package seems support several distribution, not so much.</p>
  
  <p>I explore the data with hist function, the histogram shows gamma distribution in gerneral.
  But if I add up bins and show it again, the graph will show more details, and gamma distribution fails.
  fitdistr would fail to find parameters also.
  so I want to fit the data just using the coarse data from histogram. This is the question, thank you for your help.</p>