From 386f0b45b0ab2dca207fc9eb9bb0b8a13a9856f2 Mon Sep 17 00:00:00 2001 From: tfm000 Date: Fri, 1 Dec 2023 21:49:14 +0000 Subject: [PATCH] fixing bug in rvs --- sklarpy/copulas/_prefit_dists.py | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/sklarpy/copulas/_prefit_dists.py b/sklarpy/copulas/_prefit_dists.py index f0ff7e0..34e581f 100644 --- a/sklarpy/copulas/_prefit_dists.py +++ b/sklarpy/copulas/_prefit_dists.py @@ -803,13 +803,13 @@ def copula_rvs(self, size: int, copula_params: Union[Params, tuple], raw_mv_rvs: np.ndarray = self._mv_object.rvs(size, copula_params) # bounding these above and below - eps: float = 10 ** -5 - rvs_df: pd.DataFrame = pd.DataFrame(raw_mv_rvs) - rvs_df[rvs_df < 0] = eps - rvs_df[rvs_df > 1] = 1 - eps - mv_rvs: np.ndarray = rvs_df.to_numpy() + # eps: float = 10 ** -5 + # rvs_df: pd.DataFrame = pd.DataFrame(raw_mv_rvs) + # rvs_df[rvs_df < 0] = eps + # rvs_df[rvs_df > 1] = 1 - eps + # mv_rvs: np.ndarray = rvs_df.to_numpy() - return self._g_to_u(mv_rvs, copula_params) + return self._g_to_u(raw_mv_rvs, copula_params) def _get_components_summary(self, fitted_mv_object: FittedContinuousMultivariate,