charlatan

knitr::opts_chunk$set(
  comment = "#>",
  collapse = TRUE,
  warning = FALSE,
  message = FALSE
)

Project Status: Active – The project has reached a stable, usable state and is being actively developed. Build Status Build status cran checks codecov cran version rstudio mirror downloads

charlatan makes fake data, inspired from and borrowing some code from Python's faker

Make fake data for:

Possible use cases for charlatan:

Reasons to use charlatan:

Installation

cran version

install.packages("charlatan")

dev version

devtools::install_github("ropensci/charlatan")
library("charlatan")

high level function

... for all fake data operations

x <- fraudster()
x$job()
x$name()
x$color_name()

locale support

Adding more locales through time, e.g.,

Locale support for job data

ch_job(locale = "en_US", n = 3)
ch_job(locale = "fr_FR", n = 3)
ch_job(locale = "hr_HR", n = 3)
ch_job(locale = "uk_UA", n = 3)
ch_job(locale = "zh_TW", n = 3)

For colors:

ch_color_name(locale = "en_US", n = 3)
ch_color_name(locale = "uk_UA", n = 3)

More coming soon ...

generate a dataset

ch_generate()
ch_generate('job', 'phone_number', n = 30)

person name

ch_name()
ch_name(10)

phone number

ch_phone_number()
ch_phone_number(10)

job

ch_job()
ch_job(10)

credit cards

ch_credit_card_provider()
ch_credit_card_provider(n = 4)
ch_credit_card_number()
ch_credit_card_number(n = 10)
ch_credit_card_security_code()
ch_credit_card_security_code(10)

Usage in the wild

Contributors

similar art

Meta

ropensci_footer



ropensci/charlatan documentation built on Jan. 28, 2020, 12:13 a.m.