I have a shp file with hundreds of features that represent clipped segments of coastline. Each segment is made up of many vertices (dozens, perhaps even hundreds). (FYI, the segments were created by using circles 1km in diameter to clip the coastline at random locations. The clipped segments of coastline are quite convoluted, I am looking to evaluate just how convoluted each polyline is.)
I need to calculate the fractal dimension of each individual segment (polyline). In order to be able to compare them.
I am working with ArcMap 10.1, I also just got QGIS but am not proficient with this program.
I know what the mathematical formula is to calculate fractal dimension for a single line segment, but I have far too many to calculate them individually, and I do not know how to write a script that could do it for me.
Using the box counting method: Each line segment (or segment of coastline) is covered by a sequence of grids of descending sizes and then two values are recorded for each of the grids: the number of boxes that intersect with the line, N(L), and the side length of the box, L.
Note that N(L) ∝ L^(-D)
The fractal dimension is calculated as the slope of the linear regression best-ﬁt line of log–log data.
Therefore: D = (logN)/[log(1/L)]