remove `plottable_data`
@eatyourpeas is already working on this.
Since Feb 11, 2024.
Assessment
This issue has not been assessed yet.
Description
The Measurement class returns a python object with 7 nested elements:
birth_data
measurement_dates
child_observation_value
measurement_calculated_values
bone_age
events_data
The 6th is plottable_data which has nested within it centile_data and sds_data, which in turn have nested inside them one each of chronological_decimal_age_data and corrected_decimal_age_data. The only really difference is that the decimal ages are mapped to x (depending on whether chronological or corrected) and the observation_value in the centiles, or the sds (again depending on chronological or corrected), maps to y . All the other parts are elsewhere in the object and were added there for convenience. It meant that the chart component could pull out all the elements it needed from the plottable_data object when plotting, rather than mapping different bits first.
In fact though it makes for a slightly complicated structure and it is not very DRY.
Removing plottable_data would be neater, and would make the API response object leaner and possibly faster (though arguably unlikely noticeably).
To implement this we would have to:
- bump the major version, since there maybe people out there that rely on this for their own chart implementations
- refactor the chart component to accommodate the change
- Dominant language
- Python
- Stars
- 10
- Forks
- 7
- Avg merge
- 4h 58m
- Merged PRs (30d)
- 22
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from rcpch/rcpchgrowth-python
-
enhancement
Difficulty 5/5 Over a week Newbie friendliness 35/100
rcpch/rcpchgrowth-python#109 · 1 comment ·
-
Difficulty 5/5 Over a week Newbie friendliness 35/100
rcpch/rcpchgrowth-python#79 · 1 comment ·
-
enhancement
rcpch/rcpchgrowth-python#47 · 1 assignee ·
-
bug
Difficulty 3/5 1-2 days Newbie friendliness 35/100
rcpch/rcpchgrowth-python#33 ·
-
question
rcpch/rcpchgrowth-python#21 · 1 comment · 1 assignee ·
All issues in rcpch/rcpchgrowth-python
Similar issues
-
Difficulty 2/5 1-3 hours Newbie friendliness 88/100
-
Difficulty 2/5 1-3 hours Newbie friendliness 82/100
-
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
-
enhancement
Difficulty 2/5 1-3 hours Newbie friendliness 72/100
-
Difficulty 2/5 1-3 hours Newbie friendliness 74/100