Learn R Programming

conversim (version 0.1.0)

create_windows: Create windows from a conversation

Description

This function creates a list of windows from a conversation dataframe.

Usage

create_windows(conversation, window_size)

Value

A list of character vectors, where each vector represents a window of text.

Arguments

conversation

A dataframe containing the conversation, with a column named 'processed_text'.

window_size

An integer specifying the size of each window.

Examples

Run this code
conversation <- data.frame(processed_text = c("hello", "world", "how", "are", "you"))
windows <- create_windows(conversation, 3)

Run the code above in your browser using DataLab