From 5a752fc17161413154b82b189e40d6f59b9020e4 Mon Sep 17 00:00:00 2001 From: MateoVG Date: Tue, 29 Dec 2020 11:03:27 -0500 Subject: [PATCH 1/3] Return two empty lists when there are no xings --- HARK/dcegm.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/HARK/dcegm.py b/HARK/dcegm.py index d8cd6f771..02c32d7c0 100644 --- a/HARK/dcegm.py +++ b/HARK/dcegm.py @@ -43,7 +43,7 @@ def calcCrossPoints(mGrid, condVs, optIdx): # If no crossings, return an empty list if len(idx_change) == 0: - return [] + return [], [] else: # To find the crossing points we need the extremes of the intervals in From bca2e9bf458513a9ab665aa65a40b5f38c4b055f Mon Sep 17 00:00:00 2001 From: MateoVG Date: Thu, 14 Jan 2021 10:07:10 -0500 Subject: [PATCH 2/3] Fix type signature --- HARK/dcegm.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/HARK/dcegm.py b/HARK/dcegm.py index 02c32d7c0..f13213b53 100644 --- a/HARK/dcegm.py +++ b/HARK/dcegm.py @@ -43,7 +43,7 @@ def calcCrossPoints(mGrid, condVs, optIdx): # If no crossings, return an empty list if len(idx_change) == 0: - return [], [] + return [], np.empty(0) else: # To find the crossing points we need the extremes of the intervals in From 9cccdc51d8bf867944236ee0f458b44b47cadc93 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Mateo=20Vel=C3=A1squez-Giraldo?= Date: Thu, 14 Jan 2021 11:28:01 -0500 Subject: [PATCH 3/3] Update CHANGELOG.md --- Documentation/CHANGELOG.md | 1 + 1 file changed, 1 insertion(+) diff --git a/Documentation/CHANGELOG.md b/Documentation/CHANGELOG.md index 88d6cad34..07c2aec16 100644 --- a/Documentation/CHANGELOG.md +++ b/Documentation/CHANGELOG.md @@ -20,6 +20,7 @@ Release Data: TBD * Centralizes the definition of value, marginal value, and marginal marginal value functions that use inverse-space interpolation for problems with CRRA utility. See [#888](https://github.com/econ-ark/HARK/pull/888). * MarkovProcess class (#902)[https://github.com/econ-ark/HARK/pull/902] +* Fix the return fields of `dcegm/calcCrossPoints`[#909](https://github.com/econ-ark/HARK/pull/909). #### Minor Changes