.. _f-elections: module ``data.elections`` ========================= .. inheritance-diagram:: actuariat_python.data.elections Short summary +++++++++++++ module ``actuariat_python.data.elections`` Various function to download data about **French** elections. :githublink:`%|py|6` Classes +++++++ +--------------------------------------------------------------------+-------------------------+ | class | truncated documentation | +====================================================================+=========================+ | :class:`_HTMLToText ` | | +--------------------------------------------------------------------+-------------------------+ Functions +++++++++ +---------------------------------------------------------------------------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | function | truncated documentation | +=================================================================================================================================+========================================================================================================================================================================================================================================+ | :func:`_elections_vote_place_address_patterns_ ` | | +---------------------------------------------------------------------------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | :func:`elections_legislatives_bureau_vote ` | Retrieves data from `Résultat des élections législatives françaises de 2012 au niveau bureau de vote `_. ... | +---------------------------------------------------------------------------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | :func:`elections_legislatives_circonscription_geo ` | Retrieves data from `Countours des circonscriptions des législatives `_. ... | +---------------------------------------------------------------------------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | :func:`elections_presidentielles ` | Downloads the data for the French elections from *data.gouv.fr*. | +---------------------------------------------------------------------------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | :func:`elections_presidentielles_local_files ` | Returns the list of files included in this module about French elections. | +---------------------------------------------------------------------------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | :func:`elections_vote_place_address ` | Scrapes and extracts addresses for every vote place (bureau de vote in French). | +---------------------------------------------------------------------------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | :func:`elections_vote_places_geo ` | Retrieves data vote places (bureaux de vote in French) with geocodes. | +---------------------------------------------------------------------------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | :func:`html_to_text ` | Given a piece of HTML, return the plain text it contains. This handles entities and char refs, but not javascript and ... | +---------------------------------------------------------------------------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | :func:`villes_geo ` | Retrieves data vote places (bureaux de vote in French) with geocodes. | +---------------------------------------------------------------------------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ Methods +++++++ +---------------------------------------------------------------------------------------------+-------------------------+ | method | truncated documentation | +=============================================================================================+=========================+ | :py:meth:`__init__ ` | | +---------------------------------------------------------------------------------------------+-------------------------+ | :meth:`get_text ` | | +---------------------------------------------------------------------------------------------+-------------------------+ | :meth:`handle_charref ` | | +---------------------------------------------------------------------------------------------+-------------------------+ | :meth:`handle_data ` | | +---------------------------------------------------------------------------------------------+-------------------------+ | :meth:`handle_endtag ` | | +---------------------------------------------------------------------------------------------+-------------------------+ | :meth:`handle_entityref ` | | +---------------------------------------------------------------------------------------------+-------------------------+ | :meth:`handle_startendtag ` | | +---------------------------------------------------------------------------------------------+-------------------------+ | :meth:`handle_starttag ` | | +---------------------------------------------------------------------------------------------+-------------------------+ Documentation +++++++++++++ .. automodule:: actuariat_python.data.elections :members: :special-members: __init__ :show-inheritance: