snake_case {starschemar}R 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()


[Package starschemar version 1.2.5 Index]