econmethods 3.0.3__tar.gz → 3.0.5__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: econmethods
3
- Version: 3.0.3
3
+ Version: 3.0.5
4
4
  Summary: A python package implementing various econometrical tests and estimators
5
5
  Home-page: https://github.com/NaturionBG/econmethods
6
6
  Author: NaturionBG
@@ -511,7 +511,11 @@ class FECM:
511
511
  if self.__method == 'ccemg':
512
512
  units = self.__ccemg_units
513
513
  for i, model in enumerate(units):
514
- model = model.drop(columns=drop)
514
+ if 'const' not in drop:
515
+ model = model.drop(columns=drop)
516
+ else:
517
+ self.__C = False
518
+ drop.remove('const')
515
519
  if self.__C:
516
520
  est.append(sm.OLS(model['target_diff'], sm.add_constant(model.iloc[:, 3:])).fit())
517
521
  else:
@@ -525,7 +529,11 @@ class FECM:
525
529
  elif self.__method == 'mg':
526
530
  units = self.__mg_units
527
531
  for i, model in enumerate(units):
528
- model = model.drop(columns=drop)
532
+ if 'const' not in drop:
533
+ model = model.drop(columns=drop)
534
+ else:
535
+ self.__C = False
536
+ drop.remove('const')
529
537
  if self.__C:
530
538
  est.append(sm.OLS(model['target_diff'], sm.add_constant(model.iloc[:, 3:])).fit())
531
539
  else:
@@ -534,7 +542,7 @@ class FECM:
534
542
  self.__mg_units[i] = self.__mg_units[i].drop(columns=drop)
535
543
  else:
536
544
  self.__C = False
537
- drop = drop.remove('const')
545
+ drop.remove('const')
538
546
  return est
539
547
  elif self.__method == 'ccep':
540
548
  units = self.get_ccemg_frames(self.__lag)
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: econmethods
3
- Version: 3.0.3
3
+ Version: 3.0.5
4
4
  Summary: A python package implementing various econometrical tests and estimators
5
5
  Home-page: https://github.com/NaturionBG/econmethods
6
6
  Author: NaturionBG
@@ -5,7 +5,7 @@ with open('README.md', 'r') as f:
5
5
 
6
6
  setup(
7
7
  name = 'econmethods',
8
- version = 'v3.0.3',
8
+ version = 'v3.0.5',
9
9
  description='A python package implementing various econometrical tests and estimators',
10
10
  packages = find_packages(),
11
11
  long_description=long_desc,
File without changes
File without changes