standardize_variable_names: Standardize variable names

View source: R/Standardization.R

standardize_variable_namesR Documentation

Standardize variable names

Description

Standardize variable names

Usage

standardize_variable_names(
  data,
  path = "https://raw.githubusercontent.com/CSISdefense/Lookup-Tables/master/style/",
  var = NULL,
  replace_special = FALSE
)

Arguments

data

the data frame to be joined

path

the location of the lookup file

var

the variable names to standardize; by default all will be done

replace_special

whether to replaces spaces and special characters in column names with periods

Details

This function is designed to prepare CSIS data files for lookup application. It primarily smooths out variation between different ways we've written SQL statements. It relies on a pre-existing table of variant variable names. The variable names are matched against that table in a case insensitive manner, though no other procedural standardization is applied at this time.

Value

Data with standardized variable names.

Examples

FullData<-standardize_variable_names(
  FullData,
  Path)


CSISdefense/csis360 documentation built on May 10, 2024, 1:20 a.m.