[GIS] Sum line lengths by category

lineqgisqgis-plugins

Is there any chance to calculate line lengths by category. To be precise, I have 4 road categories (state, county, local and uncategorized) and want to calculate them all within one poligone.

So far, I could calculate the lengths for all of them together, using Vector>Analysis tools>Basic statistics, in QGIS 2.10.1-Pisa. It provides me with some statistical information, like standard deviation, what I do not need.

Do I have to make 4 shape files for calculate one category of the road, or is there an add-on or a formula to calculate it?

Best Answer

Use the GroupStats plugin, which works like an Excel pivot table and allows you to calculate statistics, such as for length in your case, for various combinations of groups.