Rank: 7271 based on 9 downloads (last 30 days) and 1 file submitted
photo

Mathew

E-mail

Personal Profile:

 

Watch this Author's files

 

Files Posted by Mathew
Updated   File Tags Downloads
(last 30 days)
Comments Rating
02 Dec 2010 N-Dimensional Histogram Count Bins the elements of n matrices into an n-dimensional histogram. Author: Mathew histogram, hist, histc, ndimensional, dimension, 2d 9 2
Comments and Ratings by Mathew
Updated File Comments Rating
10 Jan 2011 N-Dimensional Histogram Count Bins the elements of n matrices into an n-dimensional histogram. Author: Mathew

Hi, I've been unable to produce this error. I tried with 4 columns of 1,000,000 data points, with 20 edge points for each dimension.

Using too many edge points (histogram bins) will make the output array too big for matlab to handle.

In the linux program 'top', I saw the MATLAB process was using around 4% of the memory (system has 4GB). Maybe you could try the code below, and see if it works on yours.
Cheers,
Mat

>> x1=rand(1000000,1);
>> x2=rand(1000000,1);
>> x3=rand(1000000,1);
>> x4=rand(1000000,1);
>> e1=linspace(0,1,20);
>> e2=e1;e3=e1;e4=e1;
>> tic;n=histcnd(x1,x2,x3,x4,e1,e2,e3,e4);toc;

Elapsed time is 2.554106 seconds.

>> size(n)

ans =

20 20 20 20

Comments and Ratings on Mathew 's Files View all
Updated File Comment by Comments Rating
10 Jan 2011 N-Dimensional Histogram Count Bins the elements of n matrices into an n-dimensional histogram. Author: Mathew Mathew

Hi, I've been unable to produce this error. I tried with 4 columns of 1,000,000 data points, with 20 edge points for each dimension.

Using too many edge points (histogram bins) will make the output array too big for matlab to handle.

In the linux program 'top', I saw the MATLAB process was using around 4% of the memory (system has 4GB). Maybe you could try the code below, and see if it works on yours.
Cheers,
Mat

>> x1=rand(1000000,1);
>> x2=rand(1000000,1);
>> x3=rand(1000000,1);
>> x4=rand(1000000,1);
>> e1=linspace(0,1,20);
>> e2=e1;e3=e1;e4=e1;
>> tic;n=histcnd(x1,x2,x3,x4,e1,e2,e3,e4);toc;

Elapsed time is 2.554106 seconds.

>> size(n)

ans =

20 20 20 20

10 Jan 2011 N-Dimensional Histogram Count Bins the elements of n matrices into an n-dimensional histogram. Author: Mathew Justin

Hello,

I'm trying to use your program but it gives me an error that says "out of memory". I've been feeding in 4 columns of 10000 data points into the program.

Regards.

Contact us