tonyfast / SpatialStatisticsFFT

A matlab function to compute Pair and Vector Resolved Spatial Statistics on Materials Science information.
tonyfast.com/SpatialStatisticsFFT/
7 stars 10 forks source link

Making SpatialStats a standalone function #7

Open tonyfast opened 10 years ago

tonyfast commented 10 years ago

Currently, you have to add a path to the functions folder which is probably unnecessary.

tonyfast commented 10 years ago

@kiransamudrala

I just put a new version of SpatialStatsFFT on the master branch. Before I close this issue, can you check the function to see if it works property. Can you attach an example figure it produces too please.

ghost commented 10 years ago

I cloned the latest version of your statistics code from master page. I tried it on a 3d checkerboard matrix.

load checkerboard.mat [T,xx] = SpatialStatsFFT(H); isocaps(T);

isocap_checkerboard

figure, isosurface(T), axis off

isosurface_checkerboard

ghost commented 10 years ago

I have a question though. When I run the following code I get a quadrant like pattern in the image. Could you tell me why? I am sure it is not the data that is causing. The reason for this pattern is definitely either the way statistics are computed or because of the usage of the post processing that I am doing. Could you help me with this? Thanks.

%% Create Data H = rand(100,100,100); V = rand(100,100,100);

%% Run statistics [T,xx] = SpatialStatsFFT(H,V);

%% Visualize Statistics % A mid section plane of x = 50 is observed sx = floor(size(T,1)/2); sy = []; sz = []; h = slice(subT,sx,sy,sz); alpha('color') set(h,'EdgeColor','none','FaceColor','interp','FaceAlpha','interp')

xmidsection

A front view of the same image is here:

xmidsection2

Why do we see those quardrants?

tonyfast commented 10 years ago

@kiransamudrala

Please see this article to better understand the functionality of the Fourier Shift in the Spatial Statistics.

I would like you to check the default visualization for the SpatialStatistics. Please sync up the master branch and run QuickStart.m. This should do the trick. I have made an article for this function too.