emend_fct_reorder: Reorder the levels of the input factor in a meaningful way.

View source: R/factor.R

emend_fct_reorderR Documentation

Reorder the levels of the input factor in a meaningful way.

Description

Reorder the levels of the input factor in a meaningful way.

Usage

emend_fct_reorder(.f, chat = get_default_chat())

Arguments

.f

A vector of characters or a factor.

chat

A chat object defined by ellmer.

Value

A factor with standardized category labels.

Examples


chat <- ellmer::chat_ollama(model = "llama3.1:8b", seed = 0, echo = "none")
emend_fct_reorder(likerts$likert1, chat = chat) |> levels()



emend documentation built on April 4, 2025, 2:38 a.m.