snake_case: Transform names according to the snake case style

View source: R/star_schema_snake_case.R

snake_caseR Documentation

Transform names according to the snake case style

Description

Transform fact, dimension, measurement, and attribute names according to the snake case style.

Usage

snake_case(st)

## S3 method for class 'star_schema'
snake_case(st)

Arguments

st

A star_schema object.

Details

This style is suitable if we are going to work with databases.

Value

A star_schema object.

See Also

Other star schema and constellation definition functions: character_dimensions(), constellation(), role_playing_dimension(), star_schema()

Examples


st <- star_schema(mrs_age, dm_mrs_age) |>
  snake_case()

st <- star_schema(mrs_age, dm_mrs_age) |>
  role_playing_dimension(
    dim_names = c("when", "when_available"),
    name = "When Common",
    attributes = c("Date", "Week", "Year")
  ) |>
  snake_case()


josesamos/starschemar documentation built on May 6, 2024, 5:57 a.m.