The behavior estimation of variables and search for their optimal value are intended to help the expected performance of companies; Therefore, this procedure becomes a relevant element for strategic organizational planning. In this sense, this article analyzes the process of patient discharge in the UPB clinic using the relative frequency, with the aim of creating a linear model that describes the behavior of the data and search for the optimum so that it allows to control the time and cost that the process must take according to the type of bed in which it is found. the patient.