ropensci / traits

R package for accessing species trait data from multiple databases
Other
40 stars 13 forks source link

Error : Bad Request (HTTP 400) #129

Closed babinecha closed 1 day ago

babinecha commented 6 months ago

Hi! I'm trying to use ncbi_byname function, but it is returning the Error : Bad Request (HTTP 400). What can I do?

ncbi_byname(taxa="Otaria flavescens", gene = c("coi", "co1"), seqrange = "1:2000")

Returns:

Working on Otaria flavescens... ...retrieving sequence IDs... Error : Bad Request (HTTP 400) NULL

dlebauer commented 4 months ago

@babinecha Do you have an API Key? Try

Sys.getenv("ENTREZ_KEY", "")

And if the result is an empty string (""), try:

(plus, note to self, I need to update the documentation)