This is the code/data repository for the manuscript:
Stella, M., Swanson, T., Li, Y., Hills, T. T., & Teixeira, A. S. (2021, May 27).
Cognitive network science as a framework for detecting structural patterns and emotions in suicide letters.
https://doi.org/10.31234/osf.io/frvta
The suicide notes have been split in sentences and subsequently parsed in terms of co-occurrences in the file sn_edgelist.tsv.
The original corpus of suicide notes was gathered by:
Schoene, A. M., & Dethlefs, N. (2016, August). Automatic identification of suicide notes from linguistic and sentiment features. In Proceedings of the 10th SIGHUM Workshop on Language Technology for Cultural Heritage, Social Sciences, and Humanities (pp. 128-133).
The code is split in two parts:
Part 1 is a Mathematica notebook containing code for producing network visualisations and emotional flowers (corresponding to the first part of the manuscript);
Part 2 is a Python notebook containing the code for producing results on emotional coherence (corresponding to the second part of the manuscript).
Emotional Recall Data necessary for reproducing the analysis is contained in the file S2_ERT_general_200.csv.
The data was gathered by:
Li, Y., Masitah, A., & Hills, T. T. (2020). The Emotional Recall Task: Juxtaposing recall and recognition-based affect scales. Journal of Experimental Psychology: Learning, Memory, and Cognition.