Out of memory

I am computing the covariance of 7x12534 matrix using the built-in function 'cov' of matlab. it is giving the following error:
??? Out of memory. Type HELP MEMORY for your options.
Error in ==> cov at 97 xy = (xc' * xc) / (m-1);
Error in ==> LOOCV_G at 25 cov_class=cov(tmp_cov(:,2:end));
kindly can anybody help me to fix this error??????

Answers (1)

Jan
Jan on 19 Dec 2011

0 votes

The problem is large: The calculated xc' * xc array requires 1.26GB of free RAM.
Either install enough RAM or reduce the problem. Perhaps you can split it into parts and use the Distributed Computing toolbox.
Using SINGLE values will reduce the memory rquirements by 50%, but it also reduced the accuracy.

Asked:

on 19 Dec 2011

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!