Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

dijkstraPath weight #76

Open
cath222ou opened this issue Jul 11, 2018 · 0 comments
Open

dijkstraPath weight #76

cath222ou opened this issue Jul 11, 2018 · 0 comments

Comments

@cath222ou
Copy link

Hello,
I tried to use dijkstraPath with a weight.
However, when I set an edge attribute as weight, I get an error 'Can not read property' toString 'of undefined'.
How i can use an edge attribute for weight ?

var poidMan1 = parseInt(featureToUpdate.getProperties().ifmanuel);
G.addNodesFrom(geometry);
G.addEdge(
start, end,
{
poidMan: poidMan1,
}
);
path = jsnx.dijkstraPath(G, {source:depart, target:arrivee, weight:poidMan });

Thanks for your help.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant