The use of complicated knowledge-driven models to optimize a process might encounter substantial numerical challenges. Because a model is an abstraction and approximation of the process, calculating the exact model optimum might not be necessary because its industrial implementation is bound to be an approximate one. Here we are exploring an alternative optimization route through a surrogate model. Because one of the decision variables affecting the optimization is time-varying, the Design of Dynamic Experiments is used to estimate the surrogate model. The process considered here is a freeze-drying one widely used in the pharmaceutical industry. The model used is a stochastic model describing the process in great detail. It is shown that the proposed data-driven route calculates the optimum is about 8 h, as opposed to 22 hours of the knowledge-driven model while sacrificing only less than 15 % in the computed value of the process performance. This article is protected by copyright. All rights reserved.