Learn R Programming

sms (version 2.3.1)

addDataAssociation: addDataAssociation

Description

Create a data lexicon for holding the associated column names

Usage

addDataAssociation(indf, data_names)

Arguments

indf
A data Lexicon (data.frame) created from the function: createLexicon
data_names
A vector vith two elements. The first element should be the name of the census data column, and the second element should be the name of the survey data column

Value

indf The imported data lexicon with one extra column.

Examples

Run this code
library(sms)
data(survey)
data(census)
in.lexicon=createLexicon()
in.lexicon=addDataAssociation(in.lexicon, c("he","he"))
in.lexicon=addDataAssociation(in.lexicon, c("females","female"))
print(in.lexicon)

Run the code above in your browser using DataLab