Skip to content

Commit c83ab3b

Browse files
committed
Linter issues
1 parent 333dc16 commit c83ab3b

File tree

3 files changed

+12
-3
lines changed

3 files changed

+12
-3
lines changed

src/mistat/design/doepy/pydoe_corrected.py

+9-3
Original file line numberDiff line numberDiff line change
@@ -538,24 +538,30 @@ def ccdesign_corrected(n, center=(4, 4), alpha="orthogonal", face="circumscribed
538538
H2, a = star(n, alpha="orthogonal", center=center)
539539

540540
# Rotatable Design
541-
if alpha.lower() in ("rotatable", "r"):
541+
elif alpha.lower() in ("rotatable", "r"):
542542
H2, a = star(n, alpha="rotatable")
543543

544+
else:
545+
raise NotImplementedError(f'Invalid value for "alpha": {alpha}')
546+
544547
# Inscribed CCD
545548
if face.lower() in ("inscribed", "cci"):
546549
H1 = ff2n_corrected(n)
547550
H1 = H1 / a # Scale down the factorial points
548551
H2, a = star(n)
549552

550553
# Faced CCD
551-
if face.lower() in ("faced", "ccf"):
554+
elif face.lower() in ("faced", "ccf"):
552555
H2, a = star(n) # Value of alpha is always 1 in Faced CCD
553556
H1 = ff2n_corrected(n)
554557

555558
# Circumscribed CCD
556-
if face.lower() in ("circumscribed", "ccc"):
559+
elif face.lower() in ("circumscribed", "ccc"):
557560
H1 = ff2n_corrected(n)
558561

562+
else:
563+
raise NotImplementedError(f'Invalid value for "face": {face}')
564+
559565
C1 = repeat_center(n, center[0])
560566
C2 = repeat_center(n, center[1])
561567

src/mistat/runsTest.py

+2
Original file line numberDiff line numberDiff line change
@@ -42,6 +42,8 @@ def runsTest(sequence, cutoff=None, alternative=None, verbose=False):
4242
pval = stats.norm.cdf(Z)
4343
elif alternative == 'greater':
4444
pval = stats.norm.cdf(-Z)
45+
else:
46+
raise NotImplementedError('alternative not implemented')
4547

4648
Result = namedtuple('Result', 'statistic,pval,method,alternative')
4749
result = Result(Z, pval, 'Runs Test', alternative)

src/pylintrc

+1
Original file line numberDiff line numberDiff line change
@@ -69,6 +69,7 @@ disable=missing-function-docstring,
6969
import-outside-toplevel,
7070
too-many-locals,
7171
too-many-statements,
72+
too-many-positional-arguments,
7273
logging-fstring-interpolation,
7374
fixme,
7475
too-many-branches,

0 commit comments

Comments
 (0)