Overview
The SIA (Sistema de Informacoes Ambulatoriais)
records all outpatient procedures performed in the Brazilian public
health system (SUS), including consultations, exams, and high-complexity
procedures. It is managed by the Ministry of Health through DATASUS.
| Coverage |
Per state (UF), all 27 states |
| Years |
2008–2024 |
| Granularity |
Monthly (one file per type/UF/month) |
| Unit |
One row per outpatient procedure record |
| Format |
.dbc files from DATASUS FTP |
File types
SIA organizes data into 13 file types. The default is PA (outpatient
production):
| PA |
Outpatient production (BPA, default) |
| BI |
Individualized BPA |
| AD |
APAC - Dialysis |
| AM |
APAC - Chemotherapy/Radiotherapy |
| AN |
APAC - Nephrology |
| AQ |
APAC - Other procedures |
| AR |
APAC - Orthopedic Surgery |
| AB |
APAC - Bariatric Surgery |
| ACF |
APAC - Cleft Lip/Palate |
| ATD |
APAC - TFD (Treatment Away from Home) |
| AMP |
APAC - Specialized Medicines |
| SAD |
RAAS - Home Care |
| PS |
RAAS - Psychosocial Care |
Downloading data
Basic download (PA type)
outpatient <- sia_data(year = 2022, uf = "AC")
Specific type
# chemotherapy/radiotherapy APAC records
chemo <- sia_data(year = 2022, uf = "SP", type = "AM")
Specific months
outpatient <- sia_data(year = 2022, uf = "SP", month = 1:3)
Filter by procedure
Use SIGTAP procedure code prefixes:
# Medical consultations (group 03.01)
consults <- sia_data(year = 2022, uf = "SP", month = 1, procedure = "0301")
# Imaging exams (group 02.04)
imaging <- sia_data(year = 2022, uf = "SP", month = 1, procedure = "0204")
Filter by diagnosis
# Diabetes-related outpatient care (E10-E14)
diabetes <- sia_data(year = 2022, uf = "SP", month = 1, diagnosis = "E1")
Select variables
outpatient <- sia_data(
year = 2022,
uf = "SP",
month = 1,
vars = c("PA_PROC_ID", "PA_CIDPRI", "PA_SEXO", "PA_IDADE",
"PA_MUNPCN", "PA_VALAPR")
)
Key variables (PA type)
| PA_PROC_ID |
Procedure code (SIGTAP) |
| PA_CIDPRI |
Principal diagnosis (CID-10) |
| PA_SEXO |
Sex (1=Male, 2=Female) |
| PA_IDADE |
Patient age |
| PA_MUNPCN |
Municipality of patient’s residence |
| PA_VALAPR |
Approved value (R$) |
| PA_QTDAPR |
Approved quantity |
| PA_CODUNI |
Health facility (CNES code) |
| PA_GESTAO |
Management level |
| PA_CONDIC |
Processing condition |
Example: Top procedures by volume
outpatient <- sia_data(year = 2022, uf = "SP", month = 1)
top_procedures <- outpatient |>
count(PA_PROC_ID, sort = TRUE) |>
head(20)
Example: Outpatient spending by diagnosis
Example: Chemotherapy APAC records
chemo <- sia_data(year = 2022, uf = "SP", type = "AM", month = 1:6)
chemo |>
count(month, name = "records") |>
arrange(month)
Smart type parsing
# parsed types (default)
outpatient <- sia_data(year = 2022, uf = "AC", month = 1)
class(outpatient$PA_VALAPR) # double
# all character
outpatient_raw <- sia_data(year = 2022, uf = "AC", month = 1, parse = FALSE)
Cache and lazy evaluation
Further reading
- SIA on DATASUS (
datasus.saude.gov.br)
- SIGTAP procedure table (
wiki.saude.gov.br/sigtap)
-
SIH vignette for hospital
admission data