Skip to content

shaoormunir/writeprints

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

28 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Writeprints Features Extractor

This python package can help extract features from a text document based on the paper Writeprints: A Stylometric Approach to Identity-Level Identification and Similarity Detection in Cyberspace.

Code was adopted from the Extended-Writeprints repository.

Installation from PyPi

To install from PyPi, run following command:

pip install writeprints

Installation from Source

To manually install from the github repository, clone the repository, go into the directory and run:

pip install ./

Usage

To extract features from a single text document contained in a python string:

from writeprints.text_processor import Processor
processor = Processor (flatten = False) # Flatten will split vectorized features into individual featurs
features = processor.extract(string)

To extract features from a pandas data frame in which a column named "text" contains the required text documents:

from writeprints.text_processor import Processor
processor = Processor (flatten = False) # Flatten will split vectorized features into individual featurs
features = processor.extract_df(df)

License

MIT

About

Extract Writeprints features from text documents

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages