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

fix bug in clip_outlier in class RobustZScoreNorm(Processor) #1294

Merged
merged 1 commit into from
Nov 11, 2022

Conversation

NotF404
Copy link
Contributor

@NotF404 NotF404 commented Sep 15, 2022

bug
it's clear, since just few lines of change.

Description

current behaver: clip_outlier in RobustZScoreNorm clip all the values in dataframe
should be: clip_outlier should just clip the group speicified by arg fields_group

e.g.
If the input dataframe contain a label lager than 3, RobustZScoreNorm will clip it to 3. (close price for example)
this pic shows right results, after fixing with this patch:
image

this pic shows wrong results, which is current results:
image

Motivation and Context

How Has This Been Tested?

  • Pass the test by running: pytest qlib/tests/test_all_pipeline.py under upper directory of qlib.
  • If you are adding a new feature, test on your own test scripts.

Screenshots of Test Results (if appropriate):

  1. Pipeline test:
  2. Your own tests:

Types of changes

  • Fix bugs
  • Add new feature
  • Update documentation

@ChiahungTai
Copy link
Collaborator

@you-n-g Will you review this patch?

@NotF404
Copy link
Contributor Author

NotF404 commented Nov 8, 2022

@you-n-g I edit this pr to make it clear, please let me know if any question.

@NotF404 NotF404 changed the title fix bug in fix clip_outlier in class RobustZScoreNorm(Processor) fix bug in clip_outlier in class RobustZScoreNorm(Processor) Nov 8, 2022
@you-n-g
Copy link
Collaborator

you-n-g commented Nov 11, 2022

Thanks!
It looks great to me!
Welcome to become one of Qlib's contributors

@you-n-g you-n-g merged commit ff2154c into microsoft:main Nov 11, 2022
@you-n-g you-n-g added the bug Something isn't working label Dec 9, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants