Rapid eye movement (REM) sleep behavior disorder (RBD) is parasomnia and a prodromal manifestation of Parkinson's disease. The current diagnostic method relies on manual scoring of polysomnograms (PSGs), a procedure that is time and effort intensive, subject to interscorer variability, and requires high level of expertise. Here, we present an automatic and interpretable diagnostic tool for RBD that analyzes PSGs using end-to-end deep neural networks. We optimized hierarchical attention networks in a 5-fold cross validation directly to classify RBD from PSG data recorded in 143 participants with RBD and 147 age-and sex-matched controls. An ensemble model using logistic regression was implemented to fuse decisions from networks trained in various signal combinations. We interpreted the networks using gradient SHAP that attribute relevance of input signals to model decisions. The ensemble model achieved a sensitivity of 91.4 % and a specificity of 86.3 %. Interpretation showed that electroencephalography (EEG) and leg electromyography (EMG) exhibited most patterns with high relevance. This study validates a robust diagnostic tool for RBD and proposes an interpretable and fully automatic framework for end-to-end modeling of other sleep disorders from PSG data. Clinical relevance- This study presents a novel diagnostic tool for RBD that considers neurophysiologic biomarkers in multiple modalities.