get_birth_month: Extract the Month of Birth from the Personal Numeric Code

Description Usage Arguments Value Examples

View source: R/get_birth_month.R

Description

This function extracts the month of birth starting from the "LL" component.

Usage

1

Arguments

cnp

a 13-digit number (or a vector of 13-digit numbers) representing the Personal Numeric Code - CNP

Value

a numeric vector representing the month of birth

Examples

1
2
3
4
5
get_birth_month(1940616346114)
get_birth_month(7041218318525)
cnps <- c(5201206346491, 1940616346114, 7041218318525, 6201206018078)
get_birth_month(cnps)
get_birth_month(c(5201206346491, 1940616346114, 7041218318525, NA))

rocnp documentation built on Nov. 5, 2021, 9:11 a.m.