Dear all,

I have tried to make 1 sigma, 2 sigma and 3 sigma contours of my data.

To calculate the levels. I took my 2d array (lets call it data).

I sorted sortData = sort(data.flatten())[::-1]

I normalized it: normSortData = sortData / sum(sortData)

Then I did the cumulative sum: cumSum = np.cumsum(normSortData)

Then I found the id with : idx = cumSum.searchsorted(0.68 this is 1 
sigma for 2 sigma its 0.954)

Then I got my level: level = sortData[idx]

I tried this out with a 2d gaussian and that level for 1 sigma was two 
much. It worked when I gave it 2*level(1 sigma).

I don't know what's going wrong.


Cheers
     Wolfgang

------------------------------------------------------------------------------
The ultimate all-in-one performance toolkit: Intel(R) Parallel Studio XE:
Pinpoint memory and threading errors before they happen.
Find and fix more than 250 security defects in the development cycle.
Locate bottlenecks in serial and parallel code that limit performance.
http://p.sf.net/sfu/intel-dev2devfeb
_______________________________________________
Matplotlib-users mailing list
Matplotlib-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/matplotlib-users

Reply via email to