[R] gdistance::shortestPath throws error "not a symmetric matrix"

Jeff Newmiller jdnewmil at dcn.davis.ca.us
Tue Feb 6 15:46:32 CET 2018

It is really hard to help you fix a function usage error if you don't show us how you used the function. [1][2][3]

As for helping a customer by asking for help on the wrong list... you are not an expert on the topic, and are asking a group that might or might not know the theory behind your question. You might achieve success, but it might also be better to remove at least one handicap by either or both strategies of having the customer ask themselves or asking on the right list. 

[1] http://stackoverflow.com/questions/5963269/how-to-make-a-great-r-reproducible-example

[2] http://adv-r.had.co.nz/Reproducibility.html

[3] https://cran.r-project.org/web/packages/reprex/index.html (read the vignette)
Sent from my phone. Please excuse my brevity.

On February 6, 2018 6:01:08 AM PST, Loris Bennett <loris.bennett at fu-berlin.de> wrote:
>  gdistance::shortestPath
>gives me the error
>  Error in asMethod(object) : 
>    not a symmetric matrix; consider forceSymmetric() or symmpart()
>The output of dput(.traceback()) is
>pairlist("stop(\"not a symmetric matrix; consider forceSymmetric() or
>  "asMethod(object)",
>  "as(Laplacian,\"symmetricMatrix\")",
>  ".Laplacian(x)", ".flowMap(x, ci, cj, tc)",
>  ".local(x, origin, goal, ...)",
>c("passage(conduct_Tobler, origin =sites at coords[5, ], goal =
>sites at coords[3, ", " ])"),
>c("passage(conduct_Tobler, origin = sites at coords[5, ], goal =
>sites at coords[3, ", " ])"),
>  "eval(ei, envir)", "eval(ei, envir)",
>  "withVisible(eval(ei, envir))",
>  "source(\"./Skript.R\")")
>Is that enough for anyone to point me in the right direction?
>I am aware that this question would be probably better posted on
>r-sig-geo, but as I am just an HPC janitor trying to help a customer
>am not a geo-scientist myself, I thought I'd ask here first before
>signing up to (yet another) list.

More information about the R-help mailing list