Prepare Data frome Human Mortality Database
data_ssvd_hmd.RdProcess data on age-specific mortality rates from a zipped file downloaded from the Human Mortality Database.
Arguments
- zipfile
The name of a zipped file downloaded from the Human Mortality Database. A path name that is handled by
utils::unzip().- n_comp
Number of SVD components to include in result. Default is
10.
Usage
Step 1: Download data
Register or log in at the Human Mortality Database, and go to page Downloading the HMD in zipped data files. Go to the "Previous Versions" table at the bottom of the page, and download a file from the "Statistics" column, eg file
https://www.mortality.org/File/Download/hmd.v6/zip/all_hmd/hmd_statistics_20240226.zip
Step 2: Call function 'svd_hmd'
Put the file into the working directory, and supply the name of the file
to function data_ssvd_hmd(), eg