I am relatively new with PROC LP. I am trying to run optimizations for a set of units across time. I.e, I want to know which units are efficient in time t, t+1, t+2, etc., to see how the efficiencies and units change over time. Noting that the input dataset needs to be in a text format, plus realizing that I want to try different inputs and outputs to the model, I am looking at developing far too many text files for my liking. Is there any way to use a SAS dataset as an input dataset for the PROC LP procedure, allowing me to set up a loop structure to rerun the model for each time period? Any help would be great.
Hi,
I assume you want to solve a linear or (mixed-)integer programming problem. PROC LP is a legacy proc, the current procs for this purpose are OPTMODEL, OPTLP and OPTMILP. Specifically for what you describe, OPTMODEL is probably the best choice. Here a link to the documentation (SAS/OR 12.1, but OPTMODEL is available since quite a few versions):
http://support.sas.com/documentation/cdl/en/ormpug/63975/HTML/default/viewer.htm#optmodel_toc.htm
I don't quite understand the details of you question, but with a basic understanding of modeling optimization problems you should be able to state the model for your optimization problem independently from the data files and OPTMODEL also supports loops.
I hope this helps
Philipp
Join us for SAS Innovate 2025, our biggest and most exciting global event of the year, in Orlando, FL, from May 6-9. Sign up by March 14 for just $795.
Learn how to run multiple linear regression models with and without interactions, presented by SAS user Alex Chaplin.
Find more tutorials on the SAS Users YouTube channel.