« View all new features in
Mathematica
9
◄
previous
|
next
►
New in
Mathematica
9
›
Advanced Image Processing with Large Image Support
Analyze Orientations in an Image
Compute and plot the orientation distribution of an image.
In[1]:=
In[2]:=
X
o = Flatten@ImageData@GradientOrientationFilter[img, 3]; w = Flatten@ImageData@GradientFilter[img, 3]; \[ScriptCapitalA] = WeightedData[o, w]; \[ScriptCapitalD] = HistogramDistribution[\[ScriptCapitalA]];
In[3]:=
X
Plot[PDF[\[ScriptCapitalD], x], {x, -\[Pi]/2, \[Pi]/2}, Filling -> Axis, Ticks -> {Range[-\[Pi]/2, \[Pi]/2, \[Pi]/4]}]
Out[3]=