Learn R Programming

NaileR (version 1.2.0)

beard_cont: Beard descriptions

Description

These data refer to 8 types of beards. Each beard was evaluated by 62 assessors (except beard 8 which only had 60 evaluations).

Usage

beard_cont

Arguments

Format

A contingency table (data frame) with 8 rows and 337 columns:

  • rows are the types of beards;

  • columns are the words used at least once to describe them.

Examples

Run this code
if (FALSE) {
# Processing time is often longer than ten seconds
# because the function uses a large language model.

library(NaileR)
data(beard_cont)

FactoMineR::descfreq(beard_cont)

intro_beard <- 'A survey was conducted about beards
and 8 types of beards were described.
In the data that follow, beards are named B1 to B8.'
intro_beard <- gsub('\n', ' ', intro_beard) |>
stringr::str_squish()

req_beard <- 'Please give a name to each beard
and summarize what makes this beard unique.'
req_beard <- gsub('\n', ' ', req_beard) |>
stringr::str_squish()

res_beard <- nail_descfreq(beard_cont,
introduction = intro_beard,
request = req_beard)
cat(res_beard$response)
}

Run the code above in your browser using DataLab