11.07.2015 Views

[U] User's Guide

[U] User's Guide

[U] User's Guide

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

[ U ] 6.2 Setting memory size on the fly: Stata/MP and Stata/SE 63Thus how big you set maxvar does not dramatically affect memory usage. Still, at maxvar=32,000,memory use is 10.072 MB.Recommendation: think about datasets with the most variables that you typically use. set maxvarto a few hundred or even 1,000 above that. (The memory cost of an extra 1,000 variables is only.315 megs.)Remember, you can always reset maxvar temporarily by typing set maxvar.Technical noteThe formula above is only approximate, and the formula given is the formula appropriate for 32-bitcomputers. When you set maxvar, Stata/MP and Stata/SE will give you a memory report showingthe exact amount of memory used:. set maxvar 10000Current memory allocationcurrentmemory usagesettable value description (1M = 1024k)set maxvar 10000 max. variables allowed 3.149Mset memory 50M max. data space 50.000Mset matsize 400 max. RHS vars in models 1.254M14.403M6.2.2 Advice on setting matsizeset matsize # [ , permanently ]where 10 ≤ # ≤ 11,000Although matsize can theoretically be set up to 11,000, on all but 64-bit computers, you willbe unable to do that, and, even if you succeeded, Stata/SE would probably run out of memorysubsequently. The value of matsize has a dramatic effect on memory usage, the formula beingmegs = (8 ∗ matsize 2 + 88 ∗ matsize)/(1024 2 )This formula is valid across all computers, 32-bit and 64-bit. For instance, the above formula statesmatsizememory use400 1.254M800 4.950M1,600 19.666M3,200 78.394M6,400 313.037M11,000 924.080M

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!