I'm working with QGIS 2.16.2 and I'm trying to use the MMQGIS hub lines plugin from the python console. For some reason the output of the process only connects a few point in the hubs shapefile with a few point in the spokes shapefile. Both shapefiles share point locations. 'centroids_distr1' contains a 'from_district' column with unique values from 1 to 12 and 'centroids_distr2' contains a 'to_district' column with repeated values from 1 to 12.
I'm new using python in QGIS so I don't know if it's a bug or it is that I am doing something the wrong way. This is the code lines I'm using:
import processing processing.runalg('qgis:hublines', 'C:/BUS/centroids_distr1.shp', 'from_district', 'C:/Documents_AGP/TUS/centroids_distr2.shp', 'to_district', 'C:/BUS/HubLines_TEST.shp')
Is there anything wrong?