I have the 'breaks' for the histogram ('hist') but I want weight the cells instead of
using actual observations. I thought that using freq=FALSE implied that the numbers in
'x' were weights but this turned out to be wrong.
Any help and/or comment is very much appreciated.
Regards,
Mårten
Marten -
I don't know exactly what interpretation you have in mind
for weights, but if you assign the value of hist() to a
variable tmp, you can then assign the component tmp$counts
any value you like, and plot the result as a histogram
using plot(tmp). See the section Value: in
hist returns a list, to which you can apply your weights.
Alternatively, in R 1.7.1, typing hist [without the quotes ()]
at a commands prompt reveals a call to UseMethod. 'methods(hist)'
identifies functions hist.default and hist.POSIXt. Typing
hist.default prodused the R code,