Tag Info

New answers tagged

5

You can also define a function that produces the required bin list: ClearAll[bF] bF[n_] := {Quantile[#, Range[# - 1]/# &[Quotient[Length@#, n]]]} & where we used the fact that the second argument of Quantile can be a List. data = RandomVariate[NormalDistribution[], 200]; Row[Histogram[data, bF[10][data], #, PlotLabel -> Style[#, 16, "Panel"], ...


7

You can use the values of the quantiles of your sample as bin delimiters for your histogram. You can think of $n$-quantiles as those threshold values that divide your data set into $n$ equal-sized subsets. Let's generate some sample data and set your requirements, i.e. number of points per bin: SeedRandom[10] sample = RandomVariate[NormalDistribution[], ...


3

While not a Bar Chart per se, I usually prefer to use the result from HistrogramList directly with ListPlot and then join the points with InterpolationOrder->0. SeedRandom[1465]; data = RandomVariate[NormalDistribution[0, 1], 1000]; mapoints=Thread[{#[[1]], Append[#[[2]], 0.0]}] &@HistogramList[data]; ListPlot[mapoints, Joined -> True, ...



Top 50 recent answers are included