Hi all,
I've got problem with SAS performance on my PC. When processing big data, it works very slow. At first, it shows the message of SAS not responding then after minute, the results are displayed! I've tried to increase the limit of memory by the syntax of : -Memsize=n but got error!
Any comment on this problem would be appreciated greatly.
Thank you
Try -memsize=max in the SAS invocation from the command line (this gives SAS as much memory as it needs subject to what is available on your machine).
@ChrisBrooks this gives SAS as much memory as it needs subject to what is available on your machine
MEMSIZE includes paging space, so is pretty much illimited.
REALMEMSIZE is the setting used to control RAM usage.
The documentation is confusing.
Speed can depend on many factors, and memory is only one of those. (Unfortunately, poor programming technique ranks high on the list.) If you want more specific advice, post the log of a slow-running program.
This may not solve the entire problem, but there are options on PROC PRINT that force SAS to look through the entire data set twice. You didn't post the log, so I can't see what options you used. Try adding a FORMAT statement that applies a format to all 6 variables, and see how much impact that has.
Is your data on your machine or a remote location and accessed over a network? Network traffic can have an impact.
How "big" is big? Number of records and variables.
Also, are using a stand alone version of SAS or connecting to a SAS server?
How did you attempt to use -Memsize=n? It would have to be either in the SAS configuration file or on a command line/ program object as the option must be set at start up and cannot be changed while running. In a server environment the Admin of the server would control users memsize.
Proc PRINT against a data set like what you described takes no more than 500 kilobytes of memory. Since I can't imagine your computer having less than 1 gigabyte of memory, i.e. at least 2000 times more than you need, poor performance you're observing has nothing to do with insufficient memory and lies elsewhere. For example, If you're printing all 64,000 observations (can't imagine whey that would be necessary), you may want to check if the destination to which you're sending the output isn't somehow constrained.
Paul D.
Are you ready for the spotlight? We're accepting content ideas for SAS Innovate 2025 to be held May 6-9 in Orlando, FL. The call is open until September 25. Read more here about why you should contribute and what is in it for you!
Learn how use the CAT functions in SAS to join values from multiple variables into a single value.
Find more tutorials on the SAS Users YouTube channel.