Repository navigation
Wealth variable renaming and codebook changes - #546
Open
LiangShi369 wants to merge 3 commits into
Open
LiangShi369 wants to merge 3 commits into
LiangShi369 wants to merge 3 commits into
Conversation
Contributor
There was a problem hiding this comment.
🔵 Needs a closer look
The supplied Java changes have no identified blockers, but the stated codebook revisions were not supplied and remain unverified.
No open issues 🎉
What changed in this PR
This PR standardizes seven wealth-module variable names and updates their callers, supporting the stated codebook alignment while preserving legacy population-data compatibility.
Changes:
- Renames pension contribution rates, membership flags, access status, and lump-sum fields and accessors.
- Preserves legacy database column names and adds a read/write compatibility test.
- Updates pension and inheritance tests to use the renamed methods.
| File | Description |
|---|---|
src/test/java/simpaths/model/person/PrivatePensionTest.java |
Updates pension tests to use renamed accessors. |
src/test/java/simpaths/model/PensionContributionCompatibilityTest.java |
Adds legacy-column read/write compatibility coverage. |
src/test/java/simpaths/model/InheritanceModuleTest.java |
Updates pension-access test setup. |
src/main/java/simpaths/model/person/PrivatePension.java |
Renames pension fields and accessors throughout. |
src/main/java/simpaths/model/Person.java |
Propagates renames while retaining legacy column mappings. |
src/main/java/simpaths/model/InheritanceModule.java |
Uses the renamed pension-access flag. |
src/main/java/simpaths/model/BenefitUnit.java |
Uses renamed contribution-rate accessors. |
src/main/java/simpaths/data/statistics/WealthValidationStats.java |
Updates contribution-rate reads. |
src/main/java/simpaths/data/Parameters.java |
Adds a comment explaining stable legacy input names. |
Review effort: Balanced
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This PR updates the codebook, and changes seven wealth-module variables so they become compatible with our naming rules. From my understanding, the variable inlcudions rule for our code books is such that:
Renamed following variales and added them into the code book:
contRateOPEewealthPensOpEeContRatePerson,PrivatePensioncontRateOPErwealthPensOpErContRatePerson,PrivatePensioncontRatePPwealthPensPpContRatePerson,PrivatePensionmemberOPwealthPensOpMemberFlagPrivatePensionmemberPPwealthPensPpMemberFlagPrivatePensionisPensionerwealthPensAccessFlagPrivatePensionlumpSumPaymentwealthPensLumpSumYearPrivatePensionI also added 11 new codebook entries:
wealthNonPensValuePerson.javawealthNonPensValueL1Person.javawealthPensAccessFlagPrivatePension.javawealthPensLumpSumYearPrivatePension.javawealthPensOpEeContRatePerson.javawealthPensOpErContRatePerson.javawealthPensOpMemberFlagPrivatePension.javawealthPensPpContRatePerson.javawealthPensPpMemberFlagPrivatePension.javawealthPensValuePerson.javawealthUnsecuredDebtHighValueBenefitUnit.javaRevised 12 codebook entries following our recent wealth-module updates in the
developbranch:| Variable | Java class
|---|---|---|
|
wealthMortgageDebtValue|BenefitUnit.java||
wealthPensValue|BenefitUnit.java||
wealthPrptyFlag|BenefitUnit.java||
wealthPrptyValue|BenefitUnit.java||
wealthTotValue|BenefitUnit.java||
xDiscConsumptionAnnual|BenefitUnit.java||
xEquivYear|Person.java||
yInvestAnnual|BenefitUnit.java||
yPensionAnnual|BenefitUnit.java||
yPensPersGrossMonth|Person.java||
yPensPersGrossMonthL1|Person.java||
yPensPersGrossMonthL2|Person.java|