Skip to main content

The PegaSUS project is divided into n modules. One of the implemented modules, called dados, allows to create a schema of a PostgreSQL database, previously created in the user computer, and to insert data that belongs to the following information health systems of the Brazilian Public Health System (SUS): CNES, SIH, SIA, SIM, SINASC or SINAN (more to come). The dados module also also allows to directly read main data files (in DBC format) and auxiliary data files (in DBF or CNV format) as pandas DataFrame objects. This second option is recommended in the case of more punctual consultation.

To use the dados module by means of a PostgreSQL database it is necessary to install the PostgreSQL DBMS (https://www.postgresql.org/download/) and it is recommended to have a database management software such as pgAdmin (https://www.pgadmin.org/download/) or DBeaver Community (https://dbeaver.io/), to proper visualize the structured data.

To use the dados module on Linux or MacOS platforms it is necessary to install the libffi dependency:

  1. Linux: $ sudo apt install libffi-dev
  2. MacOS: $ brew install libffi

For use on Windows platforms it is necessary to install the executable program (.exe) dbf2dbc, which is part of the Datasus Tabwin program. To accomplish this, download the "Tab415.zip" folder by selecting the eponymous link contained in the first line of the "Name" column of the table that appears in http://www2.datasus.gov.br/DATASUS/index.php?area=060805&item=3. Unpack the "Tab415.zip" folder, copy the executable "dbf2dbc.exe" and the file "IMPBORL.DLL" (the unpacked folder "Tab415" and its .zip can be deleted) to a newly created folder named "dbf2dbc" in the root directory of the user's computer, which generally has the following form on Windows platforms:

C:\

Finally, the data module is installed using the command(on Linux platforms):

$ sudo pip install pegasus-dados

Release files for pegasus-dados 0.2.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for pegasus-dados 0.2.0
File Size Uploaded
pegasus-dados-0.2.0.tar.gz 680.9 kB Details

Release files / pegasus-dados-0.2.0.tar.gz

Download URL pegasus-dados-0.2.0.tar.gz
Size 680.9 kB
Tags Source
SHA-256 checksum
How to use checksums
be6ff7a25edef5c20324f3f7f1e7c302a4de211a548bda6d4e381031a5617bdb
BLAKE2b-256 checksum
How to use checksums
12f1fb5aff6a03eec20cea68311e9bc624619d750dfc24a9c8499357c8a00c51
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/3.1.1 pkginfo/1.5.0.1 requests/2.23.0 setuptools/46.3.1 requests-toolbelt/0.9.1 tqdm/4.46.0 CPython/3.6.9

Release history Release notifications | RSS feed

This release

0.2.0 This release

1 release file

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page