Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Omission noise function #56

Merged
merged 2 commits into from
Apr 12, 2023
Merged

Omission noise function #56

merged 2 commits into from
Apr 12, 2023

Conversation

albrja
Copy link
Contributor

@albrja albrja commented Apr 12, 2023

Omission noise function

Adds noise function which omits a set of rows in a form.

  • Category: Feature
  • JIRA issue: MIC-3870

-adds omit rows noising function and related test suites

Testing

All tests pass successfully.

if isinstance(data, pd.Series):
not_empty_idx = data.index[(data != "") & (data.notna())]
else:
not_empty_idx = data.index
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why is this necessary? To handle row-level noise?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes. Allows for the same operation on a dataframe.

Copy link
Collaborator

@rmudambi rmudambi left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks great

pass

@pytest.fixture(scope="module")
def dummy_data():
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Don't we already have a fixture called dummy_data? Also, we're only using this fixture for the one test, so there's no need for it to have scope="module"

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think there is a dummy_dataset in test_column noise. We should also be able to use this for duplication noise function but I will remove it for now.

@albrja albrja merged commit a0b35c7 into develop Apr 12, 2023
@albrja albrja deleted the omission branch April 12, 2023 22:28
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants