-
Notifications
You must be signed in to change notification settings - Fork 66
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #232 from jpreszler/issue_129_docstring_additions
Issue 129: increase docstring coverage
- Loading branch information
Showing
24 changed files
with
1,108 additions
and
75 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,21 +1,26 @@ | ||
""" | ||
Custom Exceptions for CausalPy. | ||
""" | ||
|
||
|
||
class BadIndexException(Exception): | ||
"""Custom exception used when we have a mismatch in types between the dataframe | ||
index and an event, typically a treatment or intervention.""" | ||
|
||
def __init__(self, message): | ||
def __init__(self, message: str): | ||
self.message = message | ||
|
||
|
||
class FormulaException(Exception): | ||
"""Exception raised given when there is some error in a user-provided model | ||
formula""" | ||
|
||
def __init__(self, message): | ||
def __init__(self, message: str): | ||
self.message = message | ||
|
||
|
||
class DataException(Exception): | ||
"""Exception raised given when there is some error in user-provided dataframe""" | ||
|
||
def __init__(self, message): | ||
def __init__(self, message: str): | ||
self.message = message |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,6 @@ | ||
""" | ||
Functions to load example datasets | ||
""" | ||
import pathlib | ||
|
||
import pandas as pd | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.