
visualdatatools.com Discussion for DataTank and DataGraph

View previous topic :: View next topic 
Author 
Message 
grumpy_labrat
Joined: 03 Aug 2008 Posts: 170 Location: University of Oregon

Posted: Thu Feb 05, 2009 1:58 pm Post subject: Radial integration 


Say that I have a square grayscale image, with a centrosymetric data set in pixel position (x,y) and intensity (gray scale value, 8 bit or 16 bit), like a Fourier transform of an image from real space into reciprocal space. Is it possible to do a radial plot (see website below under "plot panel") using DT? The idea is basically to select a radius (from the center of the plot) and an arc and then have the image integrate around the radius through the arc to compress the 3D information (x,y, and Intensity) to a 2D set of data (r and Intensity).
Website with example: http://www.datasqueezesoftware.com/screenshots.html (the red/yellow/white plot is what I have, and the plot in the foreground is what I want).
Thanks! 

Back to top 


David Site Admin
Joined: 25 Nov 2006 Posts: 1964 Location: Chapel Hill, NC

Posted: Sun Feb 08, 2009 11:11 pm Post subject: 


I don't have this built in, but you can compute some of this in DT.
You can extract (by interpolation) the values along a path, and then integrate them (along arc length).
2D Path Values::Values From Mesh  to extract the values
Real Number::Integrate  to integrate along arc length.
So what you need to do is to create.
There is one way to do this, but it is slightly tedious (but much faster than coding things in C++).
Real Number::Time Sequence: Set up a time series for radii, for example howMany = 101, Value = 0.1+n*0.001 to create a series from 0.1 to 0.2 with increments of 0.001.
2D Path::Parametrized By Functions: Drag the real number in, and use that to create an arc from 0 to pi/4 or whatever angle you want. As time goes from 0 to 100, you are sweeping along the path (just adjust things).
2D Path Values::Values From Mesh: Specify mesh and path series, this gives you a time series that sweeps across, interpolating along different arcs.
Real Number::Integrate: Integrate along this path
1D Plot::Sample (x(t),y(t)): where x(t) is the radius, and y(t) is the integral.
I added a sample script: http://www.visualdatatools.com/SampleScripts/ArcLengthIntegrals.dmg
The drawback is that you have used the time dependence to handle the sweep, so it is not possible to use this on a time series of images. There is a way to do that using the Series::Script On Series, and if you want to do that I can create such a script.
You can of course create additional graphical paths and mimic the UI they gave (take in points, compute the angles using expressions, etc).
David 

Back to top 




You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum

Powered by phpBB © 2001, 2005 phpBB Group
