plot.MEM: Plot the Observed and Fitted Age-at-Death Distribution

Description Usage Arguments Details See Also Examples

View source: R/plot_MEM.R

Description

Plot the observed and fitted age-at-death distribution returned by a Oeppen, OeppenC or MEM model.

Usage

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
## S3 method for class 'MEM'
plot(x, plotType = c("fitted", "observed"), ny = 7,
  level = 80, ...)

## S3 method for class 'Oeppen'
plot(x, plotType = c("fitted", "observed"), ny = 7,
  level = 80, ...)

## S3 method for class 'OeppenC'
plot(x, plotType = c("fitted", "observed"), ny = 7,
  level = 80, ...)

Arguments

x

A fitted mortality model.

plotType

The type of the plot. The alternatives are "fitted", "observed". Default: "fitted".

ny

Number of years to be selected from input data and to be added in the plot.

level

Sets the number of quantiles the data should be broken into. Default: 80.

...

Other plotting parameters to be passed to the plotting functions. This can be used to control the appearance of the plots.

Details

Note: the output is a ggplot2 object. Therefore, one can add or modify the components of the figure.

See Also

model.Oeppen model.OeppenC model.MEM

Examples

1
# For examples go to ?model.Oeppen or ?model.OeppenC or ?model.MEM

mpascariu/MortalityForecast documentation built on Sept. 28, 2020, 2:40 p.m.