HARK
HARK copied to clipboard
`Rfree` should be `Rfree`, not `Rport`
The current implementation of models with risky assets includes the following behavior in get_Rfree
:
https://github.com/econ-ark/HARK/blob/a462169fef6c047a070239da749a4f449ecf6c89/HARK/ConsumptionSaving/ConsRiskyAssetModel.py#L270-L275
I get that the purpose of this is to recycle the transition code of models without a risky asset, sneaking in an Rfree
that is not actually the risk-free rate but the return implied by the optimal portfolio instead. However I do not think it is a good thing that a future user that is implementing a model and wants to get the risk-free rate and naively calls get_Rfree
gets something back that is not Rfree
and is forced to go hunting for the super()
that causes that; that happened to me just now.
Maybe the right thing to do is to have an Rport
that is set to Rfree
in models without risky assets. Not the other way around.