Data API Reference
Study
Dataclass representing a single study.
Attributes
| Attribute | Type | Description |
|---|---|---|
id |
int | Unique identifier |
authors |
str | Author list |
year |
int | Publication year |
title |
str | Study title |
journal |
str | Journal/source name |
study_type |
StudyType | Type of study |
primary_axis |
ThematicAxis | Primary thematic axis |
quality_rating |
QualityRating | MMAT quality rating |
doi |
Optional[str] | DOI if available |
country |
Optional[str] | First author country |
Methods
get_citation(style)
Generate a citation in the specified format.
study = db.get_study(1)
print(study.get_citation(style="apa"))
print(study.get_citation(style="vancouver"))
to_dict()
Convert to dictionary representation.
StudyDatabase
Container for managing studies.
Methods
add_study(study)
Add a study to the database.
get_study(id)
Get study by ID.
filter_by_axis(axis)
Filter by thematic axis.
filter_by_quality(rating)
Filter by quality rating.
filter_by_year(start, end)
Filter by year range.
search(query)
Search across authors, titles, journals.
Properties
studies
Iterator over all studies.
__len__
Number of studies.
Enums
ThematicAxis
from ehdslens.data import ThematicAxis
ThematicAxis.GOVERNANCE_RIGHTS_ETHICS
ThematicAxis.SECONDARY_USE_PETS
ThematicAxis.NATIONAL_IMPLEMENTATION
ThematicAxis.CITIZEN_ENGAGEMENT
ThematicAxis.FEDERATED_LEARNING_AI
QualityRating
from ehdslens.data import QualityRating
QualityRating.HIGH
QualityRating.MODERATE
QualityRating.LOW
QualityRating.NOT_APPLICABLE
StudyType
from ehdslens.data import StudyType
StudyType.QUALITATIVE
StudyType.QUANTITATIVE
StudyType.MIXED_METHODS
StudyType.THEORETICAL
StudyType.REVIEW
StudyType.POLICY_DOCUMENT
ConfidenceLevel
from ehdslens.data import ConfidenceLevel
ConfidenceLevel.HIGH
ConfidenceLevel.MODERATE
ConfidenceLevel.LOW
ConfidenceLevel.VERY_LOW
Helper Functions
load_ehds_studies()
Load the default 52 studies.