LH = [0 .2 .4 .2 .05 .05 .1]
xrange = [-1 21];
yrange = [0 1];
LH = [0 .1 .1 .4 .1 .2 .1]
HML_PMean(LH)
r = 3
b = inf;

[B,CLR,i]=HML_PBufferSP(LH, r, b, 1)

BC = [0:length(B)-1];
bar(BC,B)
xlim(xrange);
ylim(yrange);
pause

[B,CLR,i]=HML_PBufferSP(LH, r, b, 2)

BC = [0:length(B)-1];
bar(BC,B)
xlim(xrange);
ylim(yrange);
pause


[B,CLR,i]=HML_PBufferSP(LH, r, b, 5)

BC = [0:length(B)-1];
bar(BC,B)
xlim(xrange);
ylim(yrange);
pause

[B,CLR,i]=HML_PBufferSP(LH, r, b, 10)

BC = [0:length(B)-1];
bar(BC,B)
xlim(xrange);
ylim(yrange);
pause


[B,CLR,i]=HML_PBufferSP(LH, r, b, 20)

BC = [0:length(B)-1];
bar(BC,B)
xlim(xrange);
ylim(yrange);




