[Qgis-user] Distance calculation Matrix
Jonathan Moules
jonathanmoules at warwickshire.gov.uk
Wed Nov 20 03:32:39 PST 2013
Hi List,
I have a collection of ~2,500 points in British National Grid. I want to
calculate the distance between all of them to all of them.
QGIS 2 has two tools for this as best I can tell:
Processing -> "Distance matrix"
Results:
- "Linear" matrix type: Nothing happens whatsoever. No errors, no outputs,
nothing. The dialog just disappears.
- "Standard" matrix type: I get a wall of Python error message:
> Traceback (most recent call last):
> File
> "C:/PROGRA~1/QGISDU~1/apps/qgis/./python/plugins\processing\core\GeoAlgorithm.py",
> line 150, in execute
> self.processAlgorithm(progress)
> File
> "C:/PROGRA~1/QGISDU~1/apps/qgis/./python/plugins\processing\algs\ftools\PointDistance.py",
> line 98, in processAlgorithm
> self.regularMatrix(inLayer, inField, targetLayer, targetField, nPoints,
> progress)
> File
> "C:/PROGRA~1/QGISDU~1/apps/qgis/./python/plugins\processing\algs\ftools\PointDistance.py",
> line 178, in regularMatrix
> data.append(unicode(outFeat.attributes[outIdx]))
> TypeError: 'builtin_function_or_method' object has no attribute
> '__getitem__'
Summary: Absolutely nothing happens again
=========
There's also a SAGA tool "Distance matrix". With this one I get an error
like:
The following output layers could not be open
> Distance Matrix Table:
> C:\Users\jmou1\AppData\Local\Temp\processing\cb88ea8b51994f1cbfe5549465bc949f\TABLE.csv
Despite it being a location I can write to. That's using the temporary
output. If I specify an output location myself, I get the same error.
So basically, it's not working; can anyone advise what I'm doing wrong? How
do I use these tools? I've got three different failure modes here, which
isn't very encouraging.
Cheers,
Jonathan
--
This transmission is intended for the named addressee(s) only and may
contain sensitive or protectively marked material up to RESTRICTED and
should be handled accordingly. Unless you are the named addressee (or
authorised to receive it for the addressee) you may not copy or use it, or
disclose it to anyone else. If you have received this transmission in error
please notify the sender immediately. All email traffic sent to or from us,
including without limitation all GCSX traffic, may be subject to recording
and/or monitoring in accordance with relevant legislation.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/qgis-user/attachments/20131120/f568814f/attachment.html>
More information about the Qgis-user
mailing list