Learn R Programming

Biograph (version 2.0.6)

Date_as_cmc: Converts a vector of dates (class 'Date') to Century Month Codes.

Description

Converts a vector of dates (class 'Date') to months elapsed since 1st january 1900.

Usage

Date_as_cmc (x,format.in)

Arguments

x
Vector of dates. The Date vector is of class 'Date'
format.in
Format of date

Value

cmc
Dates in cmc
selectday
Day of the month

Examples

Run this code
	Date_as_cmc("2010-10-30","%Y-%m-%d")
    # cmc is 1330 and day of month is 30

Run the code above in your browser using DataLab