## 5 Conclusions  
Violence during psychiatric admissions is a problem that causes a high burden for both patients and hospital staff. Although several of its associated individual factors are known, and structured risk instruments for assessing the risk are available, meta studies reveal that generalizing these individual factors or instruments to other populations is not always straightforward. In this work, we investigated whether automatic assessment of violence risk is possible with textual data that is already captured in an Electronic Health Record (EHR). To do so, we compared classical machine learning techniques and Deep Learning techniques. For the study we used a novel and previously unexplored dataset of the University Medical Center Utrecht (UMCU) in The Netherlands. Our experiment evaluated all combinations of a text representation (Bag-of-words with binary weighting, Bag-of-words with tf-idf weighting, Word embeddings, or Document embeddings) and a classification model (Recurrent Neural Network, Convolutional Neural Network, Neural Network, Support Vector Machine, Naive Bayes, or Decision Tree). We used random search with 5-fold cross validation for optimizing hyperparameters. The results of our evaluation show that the best result is obtained by combining Document Embeddings with a Recurrent Neural Network (AUC = 0.788 \(\pm\) 0.018), closely followed by a Binary Bag of Words and a Recurrent Neural Network (AUC = 0.771 \(\pm\) 0.018), and Document Embeddings combined with a Support Vector Machine (AUC = 0.770 \(\pm\) 0.029). A relatively small but consistent improvement in performance could be seen for Deep Learning techniques over classical machine learning techniques. Deep Learning techniques furthermore have the advantage of allowing more additional experimentation with the model setup, while on the other hand, the training time of classical machine learning techniques can be up to one order of magnitude smaller. Using Deep Learning techniques on a dataset of this size and for this type of problem therefore shows promise, especially in performance critical applications. Our results finally have potential implications for the psychiatric practice as well, although the exact accuracy of automatic risk assessment from EHR data needs to be established in further research. The results we obtained are improvements over the median AUC of structured risk assessment instruments as measured in meta studies over different sites, with a comparable sample size. The proposed method using EHR data is furthermore customizable to a specific population or institution, circumventing the problem of generalization. Automatic assessment of violence risk therefore is a promising approach that can in the future provide an important addition to the psychiatric practice. Conceptualization, F.S. ; Formal analysis, V.M. ; Investigation, M.S. ; Methodology, M.S. ; Resources, F.S. ; Software, V.M. ; Supervision, F.S. and M.S. ; Validation, V.M. ; Writing--original draft, V.M. ; Writing--review & editing, F.S. and M.S. This research received no external funding. The authors would like to thank the UMCU Psydata group for their technical support. The authors declare no conflicts of interest. * [PERSON] et al. (2018) [PERSON]; [PERSON]; [PERSON]; [PERSON]; [PERSON]; [PERSON]; [PERSON]; [PERSON]; [PERSON]; [PERSON]; et al. Genetic validation of bipolar disorder identified by automated phenotyping using electronic health records. _Transl. Psychiatry_**2018**, \(8\), 86. [CrossRef] [PubMed]
* [PERSON] et al. (2013) [PERSON]; [PERSON]; [PERSON] Semi-supervised clinical text classification with Laplacian SVMs: An application to cancer case management. _J. Biomed. Inform._**2013**, _46_, 869-875. [CrossRef] [PubMed]
* [PERSON] et al. (2007) [PERSON] [PERSON]; [PERSON]; [PERSON]; [PERSON]; [PERSON]; [PERSON]; [PERSON] A shared task involving multi-label classification of clinical free text. In Proceedings of the Workshop on BioNLP 2007: Biological, Translational, and Clinical Language Processing, Prague, Czech Republic, 29 June 2007; pp.