# A White-Box Sociolinguistic Model for Gender Detection
## 3 A Sociolinguistic Model for Gender Detection
### Features  
For gender detection, researchers frequently organized the features according to the classification proposed in [4] by [PERSON] et al., who defined two basic types of features: style-based features and content-based features. Later, in [40] [PERSON] et al. suggested a classification based on six categories: lexical, syntactic, semantic, structural, domain-specific, and additional features. However, as our objective is to reveal linguistic patterns correlated to gender, we structured the features from a linguistic point of view in the following categories: orthographic, morphological, lexical, syntactic, and pragmatic-discursive. In addition, taking into account that the dataset contained digital elements, such as URLs or emoticons, we included a digital level. All features were extracted automatically with Python. In what follows, we introduce the different categories of the 198 features. Note that we indicate the number of features of each category in parentheses:  
Orthographic features (29) mainly captured punctuation marks frequencies, such as single, double and angular quotation marks, commas, full-stops, colons, semi-colons, question marks, exclamation marks, parentheses, dashes, and ellipsis points. We also extracted sequences of punctuation marks, such as duplication of question and exclamation marks, repetition of question and exclamation marks, and combinations of question and exclamation marks. Finally, we computed frequencies of alphabetic characters, repetition of vowels and consonants, upper-case and lower-case characters, combination of upper- and lower-case characters, and numeric characters. Morphological features (29) consisted of part-of-speech (PoS) tags. The word categories were extracted using petraTag ([[http://www.opentranslation.es/petratag/](http://www.opentranslation.es/petratag/)]([http://www.opentranslation.es/petratag/](http://www.opentranslation.es/petratag/)), accessed on 16 December 2021), an application developed by OpenTranslation and designed to tag corpora and obtain morphological information. Specifically, we counted the following PoS tags frequencies: nouns, adjectives, determiners (definite articles, demonstrative, possessive, indefinite, numeral, interrogative, and exclamative), pronouns (personal, demonstrative, possessive, indefinite, interrogative, exclamative, and relative), verbs (personal and non-personal verbs and verbal periphrasis), conjunctions (coordinating and subordinating conjunctions), prepositions, and interjections. Lexical features (33) captured word-based information. We applied three dictionaries to extract information about the frequencies of slang, emotive and offensive words. More specifically, we used the Spanish Specific Lexicon of Social Networks and the Spanish Emotion Lexicon created by [PERSON] ([[https://www.cic.ipn.mx/~sidorov/](https://www.cic.ipn.mx/~sidorov/)]([https://www.cic.ipn.mx/~sidorov/](https://www.cic.ipn.mx/~sidorov/)), accessed on 16 December 2021) [41] and a hand-crafted offensive word list. We also captured the use of mitigating lexical elements from the frequencies of modal and epistemic verbs, probability adjectives and adverbs, approximators, conditional tense verbs, subjunctive mood verb forms, and non-personal verbs, among other elements. Syntactic features (29) were based on syntactic dependencies. We used the _Spacy_ ([[https://spacy.io/](https://spacy.io/)]([https://spacy.io/](https://spacy.io/)), accessed on 16 December 2021) library to segment the messages into sentences and obtain the dependencies tags. We captured the following syntactic dependencies: nominal subjects, clausal subjects, direct objects, indirect objects, oblique nominal complements, nominal modifiers, adjectival modifiers, adverbial modifiers, numeric modifiers, determiners, case markers, appositional modifiers, clausal complements, open clausal complements, adverbial clause complements, and adjectival clause complements, along with syntactic relationships, such as coordination, juxtaposition, and subordination.