question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

possible coding error on bbands.py

See original GitHub issue

Which version are you running? The lastest version is on Github. Pip is for major releases.

import pandas_ta as ta
print(ta.version)

0.3.14b0

Upgrade.

$ pip install -U git+https://github.com/twopirllc/pandas-ta

Describe the bug Possible coding error at line 45 at pandas-ta/pandas_ta/volatility/bbands.py

        percent = bandwidth.shift(offset)

Expected behavior PERCENT = (close - LOWER) / (UPPER - LOWER) with shift(offset)

    # Offset
    if offset != 0:
        lower = lower.shift(offset)
        mid = mid.shift(offset)
        upper = upper.shift(offset)
        bandwidth = bandwidth.shift(offset)
        percent = percent.shift(offset)

Issue Analytics

  • State:closed
  • Created 2 years ago
  • Comments:5 (3 by maintainers)

github_iconTop GitHub Comments

1reaction
jhleongcommented, Oct 14, 2021

pull request #410 created. I requested on your development branch, is there where you work on the development ? Thank you for creating and maintaining this package. I used it a lot.

0reactions
twopirllccommented, Dec 14, 2021

Hey @jhleong,

I assume by no response that the solution provided was sufficient. Thus I will be closing this issue.

Kind Regards, KJ

Read more comments on GitHub >

github_iconTop Results From Across the Web

bollinger bands are the same for upper, middle and lower #151
Hi, I tried to get the bollinger bands, my data are valid since the EMA ... my program is running, the more likely...
Read more >
Error in running Python code for PLSR modelling
When I try to run code, it gives me error >>> python3 ensemble_plsr.py example_settings.txt. I am using Python (3.7.3), python modules ...
Read more >
Bollinger Bands Algorithm – Python Binance API for Crypto ...
Bot Trading Logic. Let's start coding the Bollinger band algorithm. As previously followed, we will design it in steps.
Read more >
Beat the market using the Bollinger Bands (Python). - Medium
First of all, if you want to go further about science and algorithmic trading, I highly recommend you to take a look at...
Read more >
Errors and exceptions - Object-Oriented Programming in Python
Syntax errors are mistakes in the use of the Python language, and are analogous to ... Find potential sources of runtime errors in...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found