The U.S. Army Corps of Engineers' Hydrologic Engineering Center's River Analysis System (HEC-RAS) is a widely used software application for performing one-dimensional and two-dimensional steady and unsteady flow river hydraulics calculations, sediment transport-mobile bed modeling, and water quality analysis. User's of HEC-RAS have often unique applications including the coupling with other software to perform system analysis such as optimization of flooding structures and multi-objective reservoir operation under uncertainty. One state-of-the-art environment for integrating software is MATLAB, which integrates computation, visualization, and programming in an easy-to-use environment. This paper presents a set of MATLAB scripts to write input files, read output files, make plots, execute parallel computations, and perform fully-automated functions of HEC-RAS. Examples of procedures are presented throughout the paper and they are illustrated using a river-reservoir network that involves ten inline structures (e.g., dams) with operation of gates at each of these dams. (C) 2016 Elsevier Ltd. All rights reserved.