Closed shenpeng2022 closed 2 years ago
Dear Peng, thanks for your interest in neuprintr/natverse. In order to help, you must give the exact sequence of commands that you are using starting for preference from an empty R session. Unfortunately the first example command you give cannot give the output you say. This is what would happen
> library(neuprintr)
> neuPrint_read_neurons(c(818983130, 1796818119))
Error in neuPrint_read_neurons(c(818983130, 1796818119)) :
could not find function "neuPrint_read_neurons"
You can find more information about how to get help more efficiently on the natverse help page. In general if you have a problem using the libraries (as opposed to a bug) or you are simply not sure, it is recommended to ask questions at https://groups.google.com/g/nat-user.
Likewise the second error message you get "Error in neuprint_login() : could not find function "neuprint_login"
is because you have not yet loaded the neuprintr library. If you do this, what happens?
library(neuprintr)
neuprint_login()
Have you already followed the instructions to store your authentication token from the README? Janelia insist that you have an authentication token in order to read neurons so this is essential.
Assuming you have, then you can continue like this and this is what would happen.
> nn=neuprint_read_neurons(c(818983130, 1796818119))
> nn
'neuronlist' containing 2 'neuprintneuron' objects and 'data.frame' with 11 vars [757.4 kB]
Hi, I run the "neuPrint_read_neurons(c(818983130, 1796818119))" in RStudio, but an error "Error reading bodyids. Likely no valid ids or no connection to neuPrint!" always comes out. I confirmed that these two neuron ids are correct on neuPrint website. I guess it might be no connection to neuPrint. So I tried neuprint_login in RStudio by using my neuprint token. However, it comes another error "Error in neuprint_login() : could not find function "neuprint_login". In addition, I found that my authorization on neuprint are noauth. I am not sure whether this will influence the connection to neuprintr. Thank you very much for your help.
All the best, Peng