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

ENH: fast stochastic oscillator added #1255

Merged
merged 9 commits into from Jun 6, 2016

Conversation

Projects
None yet
5 participants
@jonnybazookatone
Contributor

jonnybazookatone commented Jun 3, 2016

A fast stochastic oscillator has been added to the technical factors. This is the simplest of the stochastic oscillators, and can be used to build the others.

Tests have been added that compare against the values expected from that of ta-lib STOCHF. They are more basic than those used in BollingerBands.

Can't wait for suggestions ;-).

@jonnybazookatone jonnybazookatone changed the title from Enhancement/stochastic oscillator to ENH: fast stochastic oscillator added Jun 3, 2016

@coveralls

This comment has been minimized.

coveralls commented Jun 3, 2016

Coverage Status

Coverage increased (+0.01%) to 81.859% when pulling 5684165 on jonnybazookatone:enhancement/stochastic-oscillator into 1f327f5 on quantopian:master.

@ssanderson ssanderson self-assigned this Jun 3, 2016

@llllllllll

This comment has been minimized.

Member

llllllllll commented Jun 3, 2016

It appears there is 1 style violation causing the ci to fail:

tests\pipeline\test_technical.py:202:80: E501 line too long (83 > 79 characters)
@jonnybazookatone

This comment has been minimized.

Contributor

jonnybazookatone commented Jun 3, 2016

Thanks, flake8 is the bane of my existence.

window_length = 14
outputs = 'K', 'D'
def compute(self, today, assets, out, closes, lows, highs, D_period=3):

This comment has been minimized.

@ssanderson

ssanderson Jun 3, 2016

Member

This default won't ever actually be used the way the the params machinery works right now. I'd probably just make it required.

@ssanderson

This comment has been minimized.

Member

ssanderson commented Jun 6, 2016

Changes here look good to me. The branch has a merge conflict because everyone working on technical indicators at the sprint edited the bottom of the same file. @jonnybazookatone are you comfortable rebasing this and fixing the conflict? (If not, I'm happy to fix it up and merge.)

@jonnybazookatone

This comment has been minimized.

Contributor

jonnybazookatone commented Jun 6, 2016

Yeah, no problem, I'll do it by the end of today, or early tomorrow.

@jonnybazookatone jonnybazookatone force-pushed the jonnybazookatone:enhancement/stochastic-oscillator branch from 7f0d42d to b823402 Jun 6, 2016

@jonnybazookatone

This comment has been minimized.

Contributor

jonnybazookatone commented Jun 6, 2016

I borked on rebase, or it's a problem with blaze.git? I see some other PRs also failed with the same error -- coincidence?

@llllllllll

This comment has been minimized.

Member

llllllllll commented Jun 6, 2016

This was my doing, I just pushed a fix, sorry but can you rebase against master again?

edit: you were correct that it was just blaze.git that is messed up

jonnybazookatone added some commits Jun 3, 2016

ENH: fast stochastic oscillator added
A fast stochastic oscillator has been added to the technical
factors. This is the simplest of the stochastic oscillators,
and can be used to build the others.

Tests have been added that compare against the values expected
from that of ta-lib STOCHF.
ENH: fast stochastic oscillator added
Fixed the alphabetic ordering of the added classes.
ENH: fast stochastic oscillator added
Added %D parameter also, and split %K and %D as separate attributes
to the out dataframe.
ENH: fast stochastic oscillator added
Another flake8 fix, the bane of my existence.
ENH: fast stochastic oscillator added
Removed %D as it was incorrect in the way it calculates the previous
days %K values. Instead a moving average should be applied to the
FastStochasticOscillator. To allow this, the window_safe attribrute
has been added and set to True.
ENH: fast stochastic oscillator added
Fixed yet another flake8 problem.
ENH: fast stochastic oscillator added
Removed two imports I had added for the previous commit.
ENH: fast stochastic oscillator added
Fixed rebase problem that I missed.

@jonnybazookatone jonnybazookatone force-pushed the jonnybazookatone:enhancement/stochastic-oscillator branch from bd4b5fe to 629618b Jun 6, 2016

@ssanderson ssanderson merged commit 6979ae8 into quantopian:master Jun 6, 2016

2 checks passed

continuous-integration/appveyor/pr AppVeyor build succeeded
Details
continuous-integration/travis-ci/pr The Travis CI build passed
Details
@ssanderson

This comment has been minimized.

Member

ssanderson commented Jun 6, 2016

Merged. Thanks @jonnybazookatone!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment