plot.degross {degross}R Documentation

Plot the density estimate obtained from grouped summary statistics using degross and superpose it to the observed histogram.

Description

Plot the density estimate corresponding to a degross object and superpose it to the observed histogram.

Usage

## S3 method for class 'degross'
plot(x, col="black", lwd=2, lty="dashed", xlab="", ylab="Density", main="",...)

Arguments

x

A degross.object generated by degross.

col

Color used for plotting the fitted density.

lwd

Line width for the fitted density curve.

lty

Line type for the the fitted density curve.

xlab

Label on the x-axis.

ylab

Label on the y-axis.

main

Title for the generated graph.

...

Further arguments to be passed to hist.

Value

A histogram based on the observed big bin frequencies with the fitted density superposed.

Author(s)

Philippe Lambert p.lambert@uliege.be

References

Lambert, P. (2021) Moment-based density and risk estimation from grouped summary statistics. arXiv:2107.03883.

See Also

degross, degross.object, print.degross.

Examples

sim = simDegrossData(n=3500, plotting=TRUE,choice=2) ## Generate grouped data
obj.data = degrossData(Big.bins=sim$Big.bins, freq.j=sim$freq.j, m.j=sim$m.j)
print(obj.data)
obj.fit = degross(obj.data) ## Estimate the underlying density
plot(obj.fit) ## Plot the fitted density with the data histogram


[Package degross version 0.9.0 Index]