limpiar_wrap: Wrap strings for visual ease

View source: R/limpiar_wrap_strings.R

limpiar_wrapR Documentation

Wrap strings for visual ease

Description

Useful for pre-processing a dataset in which you need to read many documents, or scan over a lot of documents, e.g. when rendering an interactive scatter plot and using plotly's hover, or when using DT::datatable(escape = FALSE).

Usage

limpiar_wrap(
  data,
  text_var = mention_content,
  n = 15,
  newline_char = "<br><br>"
)

Arguments

data

Name of your Data Frame or Tibble object

text_var

Name of your text variable. Can be given as a 'string' or a symbol - should refer to a column inside data

n

number of words

newline_char

the specific delimiter to wrap the texts with

Value

Data Frame with text variable edited in place

Examples


limpiar_examples %>% limpiar_wrap(mention_content, n = 5, newline_char = "<br>")

jpcompartir/LimpiaR documentation built on Dec. 9, 2024, 9:43 p.m.