Visualizing direction-dependent values

When mapping flows or other values which relate to a certain direction, styling these layers gets interesting. I faced the same challenge when mapping direction-dependent error values. Neighboring cell pairs were connected by two lines, one in each direction, with an associated error value. This is what I came up with:

srtm_errors_1200px

Each line is drawn with an offset to the right. The size of the offset depends on the width of the line which in turn depends on the size of the error. You can see the data-defined style properties here:

directed_error_style

To indicate the direction, I added a marker line with one > marker at the center. This marker line also got assigned the same offset to match the colored line bellow. I’m quite happy with how these turned out and would love to hear about your approaches to this issue.

srtm_errors_detail

These figures are part of a recent publication with my AIT colleagues: A. Graser, J. Asamer, M. Dragaschnig: “How to Reduce Range Anxiety? The Impact of Digital Elevation Model Quality on Energy Estimates for Electric Vehicles” (2014).

Advertisement
7 comments
  1. I’m actually trying to do something very similar right now, so I’m glad stumbled on this post.
    The goal is to create a map of oil flows. Most of the stuff is going in the same direction, but here and there some stuff goes back the other way. I don’t like my method right now, which is just overlaying one of the directions on top of the other as another layer.
    I’m representing the amount of oil on each node with corresponding pen width, so I haven’t come up with a good way to offset one of the directions and have them line up. Got any ideas? I’d love some help on this one.
    Here’s a picture of what I’m working with: http://imgur.com/2qMfPmD

  2. good day Anita!
    Qgis is awesome! have all that I need to land design, but not enough creating dimension lines similar to CAD. Dimensioning plugin not working as it should. Will the creation of dimension lines in QGIS soon?

    • I haven’t heard of any plans to work on more dimensioning. Users in need of this functionality are encourage to either get in touch with the developer of the dimensioning plugin and support it’s improvement or to hire someone to add this functionality into the QGIS core. As a start, you might want to report your issues with the plugin. The plugin tracker is currently empty: https://github.com/kalxas/dimensioning/issues

  3. Gideon said:

    This is great! I like the approach of shifting the lines to visualize the intensities in each direction. This could be very helpful when styling flow maps created with the QGIS FlowMap tool. Also the paper is great. It already inspired me regarding some things that I might include in my bachelors thesis. Thank you!

    • Thank you for the kind works! I’m glad you found this post and the paper useful.

  4. Hm. As I understand this correctly, this is more of an issue with the topology of the features than one with the styling. Please see OGC simple feature specification ( http://www.opengeospatial.org/standards/sfa ) chapter 4.9 where orientation of curves is explained. On my opinion the drawing direction depends on the topology, not on any special magic.

    • I think there is a misunderstanding. All this post describes is how to create a QGIS style to vizualize flows in two directions. I’m well aware of simple features and how line direction is encoded.

%d bloggers like this: