Skip to content

Commit 2893ade

Browse files
committed
Fix linter issues
1 parent 9247f7b commit 2893ade

File tree

2 files changed

+8
-6
lines changed

2 files changed

+8
-6
lines changed

pymc_bart/bart.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -95,7 +95,7 @@ class BART(Distribution):
9595
split_rules : Optional[SplitRule], default None
9696
List of SplitRule objects, one per column in input data.
9797
Allows using different split rules for different columns. Default is ContinuousSplitRule.
98-
Other options are OneHotSplitRule and SubsetSplitRule that both apply to categorical variables.
98+
Other options are OneHotSplitRule and SubsetSplitRule, both meant for categorical variables.
9999
100100
Notes
101101
-----

pymc_bart/split_rules.py

Lines changed: 7 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -12,10 +12,9 @@
1212
# See the License for the specific language governing permissions and
1313
# limitations under the License.
1414

15+
from abc import abstractmethod
1516
from numba import njit
1617
import numpy as np
17-
from abc import abstractmethod
18-
1918

2019
class SplitRule:
2120
"""
@@ -35,7 +34,8 @@ def divide(available_splitting_values, split_value):
3534

3635
class ContinuousSplitRule(SplitRule):
3736
"""
38-
Standard continuous split rule: pick a pivot value and split depending on if variable is smaller or greater than the value picked.
37+
Standard continuous split rule: pick a pivot value and split
38+
depending on if variable is smaller or greater than the value picked.
3939
"""
4040

4141
@staticmethod
@@ -77,8 +77,10 @@ def divide(available_splitting_values, split_value):
7777

7878
class SubsetSplitRule(SplitRule):
7979
"""
80-
Choose a random subset of the categorical values and branch on if the value is within the chosen set.
81-
This is the approach taken by Sameer K. Deshpande. flexBART: Flexible Bayesian regression trees with categorical predictors. arXiv, `link <https://arxiv.org/abs/2211.04459>`__
80+
Choose a random subset of the categorical values and branch on belonging to that set.
81+
This is the approach taken by Sameer K. Deshpande.
82+
flexBART: Flexible Bayesian regression trees with categorical predictors. arXiv,
83+
`link <https://arxiv.org/abs/2211.04459>`__
8284
"""
8385

8486
@staticmethod

0 commit comments

Comments
 (0)