Date: Mar 19, 2013 12:05 AM
Author: Ernst H.K. Stelzer
Subject: Re: Smoothhistogram and log-log scaling; Fitting of a

SmoothHistogram[RandomVariate[ExponentialDistribution[1/2], 500],
PlotRange -> {{0.01, 25}, Automatic},
ScalingFunctions -> {{Log, Exp}, None}]

The option ScalingFunctions is not documented for this function but for a number of others and is not outrightly rejected for SmoothHistogram. It has an effect, but it still does not work in this case in my hands. It thin Wolfram should implement it correctly and with all *Plot2D* and *Plot3D* functions.



(+49 (69) 798 42547,

-----Original Message-----
From: Stefano Ugliano []
Sent: Monday, 18 March, 2013 10:35 AM
Subject: Smoothhistogram and log-log scaling; Fitting of a power-law

Hi all again,

Two questions in one this time, I hope this won't create any confusion: alt hough these questions sound pretty simple I haven't been able to answer them myself!

I am currently working on degree distributions on networks, and

1) I need to produce histograms of these degrees (a list of positive integers) vs their frequency. Their distribution often follows a power law, so that I am required to scale these histograms in a log-log scale.

The problem is: I really love SmoothHistogram for the clarity of its output and for automatically normalising everything, but so far I have not managed to do the log-log scaling in it, which is instead pretty straightforward with a normal Histogram... Is there any solution that joins the two worlds profitably?

2) Finally, it is important to find the "slope" of the (log-scaled) distribution, i.e. the exponent of the distribution itself. I am still not really used to fit non-polynomial functions, and I'm quite confused by the many possible approaches, which is in your opinion the best (simpler and tidier) way to proceed?

Thank you all.