text_quality: Check quality and toxicity of an input string

Description Usage Arguments Details Value Examples

Description

Check quality of the string in terms of spelling errors and toxicity content. The function performs necessary cleaning on the input string.

Usage

1

Arguments

txt

string

Details

Created on 09 February, 2019

Authors: Harjyot Kaur

Comparison is done with pre-existing list of exhaustive english words to calculate the spelling errors in the string. Comparison is done with pre-existing list of exhaustive toxic-english words to calculate the toxicity in the string.

Takes in a string and returns a data.frame with one row and two columns First column contains proportion of spelling errors in the input contains and the second column storestoxicity in the the input string.

Value

data.frame

Examples

1
2
3
txt <- "This str has words spelllll wrong. This string has a slag word shitty."

quality <- text_quality(txt)

UBC-MDS/RSyntext documentation built on May 7, 2019, 7:14 p.m.