w_SearchByInstanceof {wikiTools} | R Documentation |
Get entities which are instance of a Wikidata entity
Description
Get all Wikidata entities which are instance of one o more Wikidata entities
like films, cities, etc. If parameter langsorder
=”, then no labels or
descriptions of the entities are returned, otherwise the function returns
them in the language order indicated in langsorder
.
Usage
w_SearchByInstanceof(instanceof, langsorder = "", nlimit = 2500, debug = FALSE)
Arguments
instanceof |
Wikidata entity of which the entities searched for are an
example or member of it (class). For example, if instanceof="Q229390" return
Wikidata entities of class Q229390 (3D films). More than one entities can be
included in the
|
langsorder |
Order of languages in which the information will be returned, separated with '|'. If no information is given in the first language, next is used. If langsorder==”, then labels or descriptions are not returned. |
nlimit |
If the number of entities in the database or authorities' catalog exceeds this number, then query are made in chunks. The value can increase if langorder=”. Please, reduce the default value if error is raised. |
debug |
For debugging purposes (default FALSE). If debug='info' information about chunked queries is shown. If debug='query' also the query launched is shown. If debug='count' the function only returns the number of entities. |
Value
A data-frame. Index of the data-frame is also set to the list of entities found.
Author(s)
Angel Zazo, Department of Computer Science and Automatics, University of Salamanca
Examples
## Not run:
w <- w_SearchByInstanceof('Q229390|Q25110269', langsorder = 'es|en')
w <- w_SearchByInstanceof('Q229390&Q25110269', langsorder = 'es|en')
## End(Not run)