In the present study, particles in cell method, a Eulerian-Lagrangian approach is used to simulate the flow in an inhaler. The number of uncertain parameters, including properties of particles, fluidizing agents’ properties, initial/boundary conditions, and numerical parameters related to PIC simulations, is fourteen. The residence time of 280 PIC simulations for different values of the uncertain parameters is used to test/train a data-driven framework. The values of the uncertain parameters are generated via the Latin Hypercube Sampling method and a normal distribution. The trained algorithm is used to predict the residence time for various unknown parameters. This framework is used to carry out the sensitivity analysis to find the most influential settings on the residence time of the particles in the inhaler. The optimum parameters of the influential parameters for a given residence time is calculated via the data-driven framework.