I'm looking to use a derivative-free optimization method to estimate a set of parameters that would be written to some external datasets that would then be used in separate executable files to see how consistent observed data are to the candidate parameter values. These executable files would output negative log likelihood values and predictions, which would then be read back into the optimization function. The model predictions would be used to calculate some additional objective function components, that would be combined with the executable objective functions. The idea being to find parameter values that are consistent with the data and procedures in the separate executable files and the predictions are consistent with some additional data. The processes in the executable files are fairly complex and it would not be trivial to build/recode those executables in SAS. I have been able to program this in R, but it doesn't seem to work well because the search algorithms aren't really exploring the parameter space very well even though I have scaled the parameters appropriately. I'm thinking that the problem might be is that because of the executables being called methods like finite differences aren't working well to figure out step sizes for the parameter search. Before attempting to program this in SAS, I was just curious if anyone on the list had similarly tried optimization that involved interacting with separate executable programs (i.e., writing data out to be used in executables and reading in executable results). Any suggestion would be appreciated. If the process I'm trying isn't clear, I could produce pseudo-code that might make it more clear what I am attempting.