Comments (3)
Looks like some functions work, but not others.
library(citecorp)
doi1 <- "10.1108/jd-12-2013-0166"
oc_coci_cites(doi1) # works
oc_coci_refs(doi1) # works
oc_coci_meta(doi1) # works
These use the REST endpoint.
But these rely on SPARQL:
oc_doi2ids(doi1) # 0 columns, 0 rows
The same type of query pasted onto the https://opencitations.net/meta/sparql sandbox seems to work:
PREFIX datacite: <http://purl.org/spar/datacite/>
PREFIX literal: <http://www.essepuntato.it/2010/06/literalreification/>
SELECT ?paper ?pmid ?pmcid ?value
WHERE {
{
?paper datacite:hasIdentifier [
datacite:usesIdentifierScheme datacite:doi ;
literal:hasLiteralValue ?value
] .
OPTIONAL {
?paper datacite:hasIdentifier [
datacite:usesIdentifierScheme datacite:pmid ;
literal:hasLiteralValue ?pmid
] .
}
OPTIONAL {
?paper datacite:hasIdentifier [
datacite:usesIdentifierScheme datacite:pmcid ;
literal:hasLiteralValue ?pmcid
] .
}
} .
VALUES ?value { "10.1093/biomet/80.3.527" }
}
returning the following output
{
"head" : {
"vars" : [ "paper", "pmid", "pmcid", "value" ]
},
"results" : {
"bindings" : [ {
"value" : {
"type" : "literal",
"value" : "10.1093/biomet/80.3.527"
},
"paper" : {
"type" : "uri",
"value" : "https://w3id.org/oc/meta/br/06250321084"
}
} ]
}
}
But when the R package does it, the results$bindings
are empty. Will try to debug this: maybe it is calling the wrong endpoint or something.
from citecorp.
@rkrug I have just pushed a fix, which seems to work now for oc_doi2ids("10.1097/igc.0000000000000609")
and other examples I tried.
Neither oc_pmid2ids
nor oc_pmcid2ids
produce results for the examples in the Examples section of the documentation, but they give the same output as the sandbox, so that appears to be a separate issue.
from citecorp.
Thanks - I actually need the function oc_coci_refs()
which is still not working. I think it is a similar issue.
from citecorp.
Related Issues (9)
- allow length > 1 id input in id converter fxns HOT 6
- PMID / PMCIDs not returned by SPARQL endpoint
- Error in doi2ids - arguments imply differing number of rows: 0, 1 HOT 1
- make sure egs run only if okay
- oc_coci_cites() fails with multiple DOIs HOT 3
- add test for cloudflare status codes
- Maintenance status / help needed? HOT 2
- Paginate oc_coci_meta() or warn when there are too many DOIs? HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from citecorp.