ait-energy / qgis-edge-bundling

GNU General Public License v2.0
64 stars 14 forks source link

Configuring edge bundling parameters for regional UK data in WGS84 #4

Closed brylie closed 6 years ago

brylie commented 6 years ago

When running the edge bundler, I am getting the following results: screenshot from 2017-11-02 14-07-17

Steps to reproduce

  1. load in origin-destination network (with non-zero lengths)
  2. cluster lines with kmeans ideal number of clusters
  3. bundle edges

Here is the extent of the original data: screenshot from 2017-11-02 14-12-41

anitagraser commented 6 years ago

What's your input data CRS? Which settings are you using in edge bundling?

brylie commented 6 years ago

What's your input data CRS? Which settings are you using in edge bundling?

That is an understandable question. I will check whether I can share the data, so you can reproduce. I am pretty much using the default settings, but will provide those as well.

anitagraser commented 6 years ago

The default settings won't work for data in WGS84. For example, the default step size is 100. That means that, at the first processing step, intermediate nodes are moved by 100 degrees. The results can never recover from this huge displacement.

brylie commented 6 years ago

Ah, that makes sense ☺ I will try this again with different settings on Monday. What would be a better default step size, 0.5?

anitagraser commented 6 years ago

Try 0.001° ~ 100m

brylie commented 6 years ago

OK, good suggestion. I have tried various settings for the default step size, and get the following result with 0.05:

screenshot from 2017-11-06 11-06-04

How do I reduce the jaggedness of the lines (i.e. they are very zig-zaggey)? How do I apply your flow arrow styles to the output?

anitagraser commented 6 years ago

Still too big. Did you try 0.001 as I recommended?

brylie commented 6 years ago

Yep, here are the results with 0.001:

screenshot from 2017-11-06 15-48-33

anitagraser commented 6 years ago

That looks ok. Now you need to run summarize.py and then you can configure data-defined line widths.

It is not possible to use arrows to style bundling results, as discussed in the paper.

brylie commented 6 years ago

Now you need to run summarize.py and then you can configure data-defined line widths

I have run the summarize module, and produced an output layer. What layer column should I use to control the line widths, MERGED_N (i.e. what does the MERGED_N column mean)? Do you have an example rule for setting line width based on MERGED_N (e.g. a recipe or tutorial)?

anitagraser commented 6 years ago

It's impossible to provide a generic style because n will be different for each dataset. Use the Size assistant to get help with creating a suitable style expression:

menu_198

brylie commented 6 years ago

I have been working with the line widths and colors this morning, and have some decent results.

One strange thing that I am noticing is that some of the lines appear to be 'smeared' together: screenshot from 2017-11-07 11-18-36

What do you think might be the underlying cause of the smearing lines (e.g. lines from different clusters being bundled together)?

anitagraser commented 6 years ago

Do you mean the effect of bundles varying in color in your above screenshot? You might want to try with a bigger tolerance in the summarization step.

brylie commented 6 years ago

Yeah, the yellow and red striping in the above image. It seems like multiple lines, possibly from different clusters, are overlapping on the same space. However, when I ran the same analysis without clusters, there was still, albeit reduced, striping.

anitagraser commented 6 years ago

I expect that it's a summarization issue. It's not trivial to compute the local bundle strength.

brylie commented 6 years ago

OK, cool. I am not actively working with the data right now, so it may be some time before I can come back to it. In the meantime, we can close this issue.

brylie commented 6 years ago

Thanks for all of your help to teach me how to use the edge bundler :-)