rcrossref
rcrossref copied to clipboard
Field queries are not working
Steps to reproduce (following the documentation):
query.author
resT1 <- cr_works(query = "ecology", flq = c(query.author = 'Boettiger')) noResT1 = resT1$meta$total_results
query.container-title
resT2 <- cr_works(query = "ecology",
flq = c(query.container-title
= 'Ecology'))
noResT2 = resT2$meta$total_results
These searches give exactly the same results, suggesting the 'flq' term is not working. Since the 'query' field only allows for OR logic, it seems that no AND logic is possible.
Hi @willguest,
Thanks for your report. Can you please provide a reproducible example. I cannot reproduce your report:
library(rcrossref)
cr_works(query = "ecology", flq = c(query.author = 'Boettiger'))
#> $meta
#> total_results search_terms start_index items_per_page
#> 1 17 ecology 0 20
#>
#> $data
#> # A tibble: 17 × 36
#> alternative.id container.title created deposited published.online doi
#> <chr> <chr> <chr> <chr> <chr> <chr>
#> 1 477 Theoretical Ecol… 2020-0… 2021-08-… 2020-08-07 10.100…
#> 2 <NA> <NA> 2016-0… 2019-07-… <NA> 10.110…
#> 3 10.1111/ele.130… Ecology Letters 2018-0… 2021-06-… 2018-05-22 10.111…
#> 4 <NA> Methods in Ecolo… 2012-1… 2020-10-… 2012-10-11 10.111…
#> 5 192 Theoretical Ecol… 2013-0… 2019-07-… 2013-06-21 10.100…
#> 6 <NA> <NA> 2015-0… 2020-01-… <NA> 10.110…
#> 7 10.1002/ece3.23… Ecology and Evol… 2016-0… 2021-07-… 2016-08-18 10.100…
#> 8 10.1111/2041-21… Methods in Ecolo… 2020-0… 2021-06-… 2020-08-02 10.111…
#> 9 10.1111/2041-21… Methods in Ecolo… 2015-0… 2021-07-… 2015-10-19 10.111…
#> 10 10.1177/2053951… Big Data & Socie… 2019-0… 2020-12-… 2019-03-25 10.117…
#> 11 10.1890/10-0106… Ecology 2011-0… 2019-06-… <NA> 10.189…
#> 12 10.1111/2041-21… Methods in Ecolo… 2020-1… 2020-12-… 2020-10-21 10.111…
#> 13 10.1111/ele.138… Ecology Letters 2021-0… 2021-08-… 2021-07-04 10.111…
#> 14 <NA> <NA> 2019-0… 2021-06-… <NA> 10.110…
#> 15 518 Theoretical Ecol… 2021-0… 2021-07-… 2021-07-09 10.100…
#> 16 <NA> <NA> 2018-0… 2020-01-… <NA> 10.110…
#> 17 10.1111/ele.128… Ecology Letters 2017-1… 2021-07-… 2017-12-27 10.111…
#> # … with 30 more variables: indexed <chr>, issn <chr>, issued <chr>,
#> # member <chr>, prefix <chr>, publisher <chr>, score <chr>, source <chr>,
#> # reference.count <chr>, references.count <chr>,
#> # is.referenced.by.count <chr>, subject <chr>, title <chr>, type <chr>,
#> # update.policy <chr>, url <chr>, language <chr>,
#> # short.container.title <chr>, assertion <list>, author <list>,
#> # funder <list>, link <list>, license <list>, reference <list>, …
#>
#> $facets
#> NULL
cr_works(query = "ecology", flq = c(`query.container-title` = 'Ecology'))
#> $meta
#> total_results search_terms start_index items_per_page
#> 1 322855 ecology 0 20
#>
#> $data
#> # A tibble: 20 × 29
#> container.title created deposited published.online doi indexed issued
#> <chr> <chr> <chr> <chr> <chr> <chr> <chr>
#> 1 Ecology 2013-03-19 2020-05-27 2012-05-23 10.109… 2021-0… 2012-…
#> 2 Ecology 2015-02-03 2020-05-27 2015-01-15 10.109… 2021-0… 2015-…
#> 3 Ecology 2013-03-19 2020-03-25 2012-05-23 10.109… 2021-0… 2012-…
#> 4 Ecology 2013-03-19 2020-05-27 2012-05-23 10.109… 2021-0… 2012-…
#> 5 Ecology 2018-08-28 2021-07-27 2018-08-28 10.109… 2021-0… 2018-…
#> 6 Ecology 2013-03-19 2020-05-27 2012-05-23 10.109… 2021-0… 2012-…
#> 7 Ecology 2013-03-19 2020-05-27 2012-05-23 10.109… 2021-0… 2012-…
#> 8 Ecology 2019-07-31 2019-07-31 2019-07-31 10.109… 2021-0… 2019-…
#> 9 Ecology 2019-07-31 2019-07-31 2019-07-31 10.109… 2021-0… 2019-…
#> 10 Ecology 2013-03-19 2021-05-25 2012-05-23 10.109… 2021-0… 2012-…
#> 11 Ecology 2018-06-27 2020-03-25 2018-06-27 10.109… 2021-0… 2018-…
#> 12 Ecology 2016-02-03 2021-05-25 2016-01-21 10.109… 2021-0… 2016-…
#> 13 Ecology 2018-03-28 2021-05-25 2018-03-28 10.109… 2021-0… 2018-…
#> 14 Ecology 2018-01-11 2020-05-27 2018-01-11 10.109… 2021-0… 2018-…
#> 15 Ecology 2019-07-31 2019-07-31 2019-07-31 10.109… 2021-0… 2019-…
#> 16 Ecology 2021-01-13 2021-01-13 2021-01-12 10.109… 2021-0… 2021-…
#> 17 Ecology 2019-03-28 2021-05-25 2019-03-27 10.109… 2021-0… 2019-…
#> 18 Ecology 2006-05-03 2018-08-04 <NA> 10.230… 2021-0… 1957-…
#> 19 Ecology 2006-05-03 2018-08-04 <NA> 10.230… 2021-0… 1966-…
#> 20 Ecology 2006-05-03 2018-08-04 <NA> 10.230… 2021-0… 1957-…
#> # … with 22 more variables: member <chr>, prefix <chr>, publisher <chr>,
#> # score <chr>, source <chr>, reference.count <chr>, references.count <chr>,
#> # is.referenced.by.count <chr>, title <chr>, type <chr>, url <chr>,
#> # abstract <chr>, author <list>, published.print <chr>, issn <chr>,
#> # issue <chr>, page <chr>, subject <chr>, volume <chr>,
#> # short.container.title <chr>, link <list>, license <list>
#>
#> $facets
#> NULL
Created on 2021-08-18 by the reprex package (v2.0.0)