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

[Bug] economy/pred/regression - the use of any optional argument produces an error: "regression: error: argument -p/--polynomial: expected one argument" #1574

Closed
deeleeramone opened this issue Mar 28, 2022 · 5 comments · Fixed by #1639
Assignees
Labels
bug Fix bug

Comments

@deeleeramone
Copy link
Contributor

[Bug] economy/pred/regression - the use of any optional argument - other than help - results in an error message
"regression: error: argument -p/--polynomial: expected one argument"

2022 Mar 28, 18:27 (✨) /economy/pred/ $ regression

Screen Shot 2022-03-28 at 3 30 17 PM

2022 Mar 28, 18:27 (✨) /economy/pred/ $ regression -p 1
usage: regression [-i N_INPUTS] [-d N_DAYS] [-j N_JUMPS] [-e S_END_DATE] [-p N_POLYNOMIAL] [-h] [--export EXPORT]
regression: error: argument -p/--polynomial: expected one argument

2022 Mar 28, 18:27 (✨) /economy/pred/ $ regression -d 10
usage: regression [-i N_INPUTS] [-d N_DAYS] [-j N_JUMPS] [-e S_END_DATE] [-p N_POLYNOMIAL] [-h] [--export EXPORT]
regression: error: argument -p/--polynomial: expected one argument

@piiq piiq added the bug Fix bug label Mar 29, 2022
@Chavithra
Copy link
Contributor

@deeleeramone is that issue still relevant ?

Thanks

@deeleeramone
Copy link
Contributor Author

The issue appears when jumping from the economy menu with stored data to the prediction menu.


2022 Apr 04, 12:15 (🦋) /economy/pred/ $ regression



        Actual price: 2.11 $        
                                    
┏━━━━━━━━━━━━━━━━━━━━━┳━━━━━━━━━━━━┓
┃ Datetime            ┃ Prediction ┃
┡━━━━━━━━━━━━━━━━━━━━━╇━━━━━━━━━━━━┩
│ 2022-03-02 00:00:00 │ 2.23 $     │
├─────────────────────┼────────────┤
│ 2022-03-03 00:00:00 │ 2.11 $     │
├─────────────────────┼────────────┤
│ 2022-03-04 00:00:00 │ 2.11 $     │
├─────────────────────┼────────────┤
│ 2022-03-07 00:00:00 │ 2.12 $     │
├─────────────────────┼────────────┤
│ 2022-03-08 00:00:00 │ 2.12 $     │
└─────────────────────┴────────────┘
2022 Apr 04, 12:15 (🦋) /economy/pred/ $ regression -p 2
usage: regression [-i N_INPUTS] [-d N_DAYS] [-j N_JUMPS] [-e S_END_DATE] [-p N_POLYNOMIAL] [-h] [--export EXPORT]
regression: error: argument -p/--polynomial: expected one argument

@LBolte29
Copy link
Contributor

LBolte29 commented Apr 5, 2022

@deeleeramone
Could you put the exact sequence of commands necessary to reproduce this?

@deeleeramone
Copy link
Contributor Author

deeleeramone commented Apr 5, 2022

p could be any value here.

2022 Apr 05, 02:10 (🦋) /economy/ $ index russel

2022 Apr 05, 02:11 (🦋) /economy/ $ index russel -st/pred/regression -p 2
2022 Apr 05, 02:11 (🦋) /economy/ $ index russel -st
2022 Apr 05, 02:11 (🦋) /economy/ $ pred
2022 Apr 05, 02:11 (🦋) /economy/pred/ $ regression -p 2
usage: regression [-i N_INPUTS] [-d N_DAYS] [-j N_JUMPS] [-e S_END_DATE] [-p N_POLYNOMIAL] [-h] [--export EXPORT]
regression: error: argument -p/--polynomial: expected one argument

@deeleeramone
Copy link
Contributor Author

here is removing the -p flag

2022 Apr 05, 02:11 (🦋) /economy/pred/ $ ..

2022 Apr 05, 02:12 (🦋) /economy/ $ index russel -st/pred/regression
2022 Apr 05, 02:12 (🦋) /economy/ $ index russel -st
2022 Apr 05, 02:12 (🦋) /economy/ $ pred
2022 Apr 05, 02:12 (🦋) /economy/pred/ $ regression



      Actual price: 2095.44 $       
                                    
┏━━━━━━━━━━━━━━━━━━━━━┳━━━━━━━━━━━━┓
┃ Datetime            ┃ Prediction ┃
┡━━━━━━━━━━━━━━━━━━━━━╇━━━━━━━━━━━━┩
│ 2022-04-05 00:00:00 │ 2097.30 $  │
├─────────────────────┼────────────┤
│ 2022-04-06 00:00:00 │ 2096.49 $  │
├─────────────────────┼────────────┤
│ 2022-04-07 00:00:00 │ 2101.76 $  │
├─────────────────────┼────────────┤
│ 2022-04-08 00:00:00 │ 2095.00 $  │
├─────────────────────┼────────────┤
│ 2022-04-11 00:00:00 │ 2095.57 $  │
└─────────────────────┴────────────┘

Chavithra pushed a commit that referenced this issue Apr 6, 2022
* fix logic

* meeting with chavi

* black

* changed logic

* fix reddit credentials

Co-authored-by: Colin Delahunty <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Fix bug
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants