Comments (2)
Thank you very much for your detailed bug report. I think you are correct. If you want to send a PR, please feel free to do so. Otherwise, I'll fix it aligned with your note here. If you happen to have some test data that can be used for unit testing here please let me know as well.
from indicator.
It's ok to copy and paste this code so please feel free to do so,
you can test for SinceHigh
values := []float64{29503, 29515, 29527, 29579, 29631, 29665, 29490, 29449, 29420, 29438}
for period := 3
expected := []int{0, 0, 0, 0, 0, 0, 1, 2, 3, 3}
and for period = 5
expected := [0 0 0 0 0 0 1 2 3 4]
I guess you can make many more if you like :)
Please let me know if you need any more help
from indicator.
Related Issues (20)
- Add Generator support for streams HOT 1
- Go Report Card - momentum/ichimoku_cloud.go - Line 27: warning: "resistence" is a misspelling of "resistance" (misspell)
- Go Report Card - helper/divide.go - Line 17: warning: "divison" is a misspelling of "division" (misspell)
- module github.com/cinar/indicator/v2@latest found (v2.0.1), but does not contain package github.com/cinar/indicator/v2 HOT 7
- True Strength Index (TSI) Strategy HOT 1
- Snapshot Volume also float64 instead of int64 !? HOT 5
- Option to set the time format for the reports HOT 2
- Backtest to take LastDate as the reference point
- devcontainer still uses Go version 1.20
- The comment for helper.Shift is slightly wrong. HOT 1
- Integration of other marketdata vendors / alpaca.markets HOT 9
- The ATR calculation process is wrong HOT 2
- Introduce workflow for doc HOT 5
- Wash sale protection in strategies
- Add a timestamp to backtest report
- Deepsource: Multiple append can be combined into a single call
- Deepsource: Use http.NoBody instead of nil in http.NewRequest calls
- Deepsource: Use %q to quote a string in fmt.Sprintf format specifiers
- Deepsource: Types of function parameters can be combined
- Strategies should return nonnormalized recommendations
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from indicator.