Laboratory#
Management of a group of people and their publications is made with the Lab
abstract class.
- class gismap.lab.lab.AuthorMetadata(url: str = None, img: str = None, group: str = None, position: tuple = None)[source]#
Optional information about an author to be used to enhance her presentation.
- class gismap.lab.lab.Lab(name=None, dbs=None)[source]#
Abstract class for labs.
Labs can be saved with the dump method and loaded with the load method.
- Parameters:
- update_publis()[source]#
Populate the publications attribute (
dict
[str
,SourcedPublication
]).- Return type:
None
- class gismap.lab.lab.LabAuthor(name: str, sources: list = <factory>, metadata: gismap.lab.lab.AuthorMetadata = <factory>)[source]#
- class gismap.lab.lab.ListLab(author_list, *args, **kwargs)[source]#
Simplest way to create a lab: with a list of names.
Collaboration graph#
- gismap.lab.graph.author_to_html(author)[source]#
- Parameters:
author (
Author
) – Searcher.- Return type:
HTML string with URL if applicable.
- gismap.lab.graph.lab2graph(lab)[source]#
- Parameters:
lab (
Lab
) – A lab populated with searchers and publications.- Returns:
Collaboration graph.
- Return type:
Examples
>>> from gismap.lab import ListLab >>> lab = ListLab(author_list=['Tixeuil Sébastien', 'Mathieu Fabien'], name='mini') >>> lab.update_authors() >>> lab.update_publis() >>> len(lab.authors) 2 >>> len(lab.publications) 435 >>> html = lab2graph(lab) >>> html[:80] '\n<div id="mynetwork_..."></div>\n<div id="modal_..." class="modal">\n <'
- gismap.lab.graph.publication_to_html(pub)[source]#
- Parameters:
pub (
Publication
) – Publication.- Return type:
HTML string with hyperlinks where applicable.
- gismap.lab.graph.publications_list_html(publications, n=10)[source]#
- Parameters:
publications (
list
ofPublication
) – Publications to display.n (
int
, default=10) – Number of publications to display. If there are more publications, a Show more option is available to unravel them.
- Return type: