-
Notifications
You must be signed in to change notification settings - Fork 3
Noise methods
Isabel edited this page May 12, 2023
·
5 revisions
Binomial noise is named after the distribution of the features it is suitable for. Features that follow the binomial distribution are typically binary or count data.
Binomial_noise(clean_data, level, feature_name=None, random_state=None):
Parameters: |
clean_data: ndarray or dataframe of shape (n_samples, n_features) Array of the feature values that will be permuted. If dataframe, feature_name is required to determine which feature the noise should be applied to. |
|
level: float The probability of each value to be permuted. If 0, feature is returned without changes. If 1, every value is flipped. |
|
|
feature_name: str, deafult=None If clean_data is a dataframe feature name is required to determine which feature will be permuted. |
|
|
random_state: int, RandomState instance or None, deafult=None Controls randomness in drawing from the distribution. |
Returns: |
result: ndarray or dataframe of shape (n_samples, n_features) Array or dataframe (depends on input format) with the noisy feature permuted. |
#Continuos