structural_similarity: Calculate structural similarity between two conversations

View source: R/main_functions.R

structural_similarityR Documentation

Calculate structural similarity between two conversations

Description

This function calculates the structural similarity between two conversations based on their length and average turn length.

Usage

structural_similarity(conv1, conv2)

Arguments

conv1

A character vector representing the first conversation

conv2

A character vector representing the second conversation

Value

A numeric value representing the structural similarity

Examples

conv1 <- c("Hello", "Hi there", "How are you?", "I'm fine, thanks")
conv2 <- c("Good morning", "Hello", "Nice day, isn't it?", "Yes, indeed")
structural_similarity(conv1, conv2)

conversim documentation built on Sept. 20, 2024, 5:09 p.m.