econmethods 2.0.1__tar.gz → 2.1__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: 2.0.1
3
+ Version: 2.1
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
@@ -634,6 +634,7 @@ class SlopeHomogeneityF:
634
634
  </ul>
635
635
  <li> <strong>level</strong>: Your significance level to test at. Defaults to 5%.</li>
636
636
  <li> <strong>intercept</strong>: Specify whether your model has an intercept. Defaults to True.</li>
637
+ <li> <strong>skip_premise</strong>: Set to True if you wish to ignore heteroskedasticity. Not a recommended option, parameter defaults to False</li>
637
638
  </ul>
638
639
  <hr>
639
640
  <h3><em>Note that this test has got certain assumptions, such as error homoskedasticity, N < T.
@@ -644,12 +645,13 @@ class SlopeHomogeneityF:
644
645
  <li>Via the instance.verdict() method - prints the result of the F-test.</li>
645
646
  </ol>
646
647
  '''
647
- def __init__(self, df: pd.DataFrame, level: int = 5, intercept: bool = True) -> None:
648
+ def __init__(self, df: pd.DataFrame, level: int = 5, intercept: bool = True, skip_premise: bool = False) -> None:
648
649
  self.__df = df
649
650
  self.__l = []
650
651
  self.__C = intercept
651
652
  self.__alpha = level/100
652
653
  self.__k = 0
654
+ self.__skip = skip_premise
653
655
  for i, ex in enumerate(self.__df.columns[3:], 1):
654
656
  self.__k +=1
655
657
  self.__l.append(f'x{i}')
@@ -663,7 +665,10 @@ class SlopeHomogeneityF:
663
665
  if self.__N > self.__T:
664
666
  raise AssertionError('The F-test for slope Homogeneity assumes that N< T!')
665
667
  if self.__homo_res[1] < self.__alpha:
666
- raise AssertionError('The Data contains Heteroskedastic errors according to the Goldfeld-Quandt test!')
668
+ if not self.__skip:
669
+ raise AssertionError('The Data contains Heteroskedastic errors according to the Goldfeld-Quandt test!')
670
+ else:
671
+ pass
667
672
 
668
673
  def fit(self) -> float | int:
669
674
  USSR = 0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: econmethods
3
- Version: 2.0.1
3
+ Version: 2.1
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 = 'v2.0.1',
8
+ version = 'v2.1',
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