Comments (7)
@viveksp were you able to fix it at all? PSAR indicator isn't working at all
from btplotting.
Go ahead with the PR. I replaced lately some markers which did not work, too
from btplotting.
@Jake0303 I encountered the same issue with PSAR in backtrader-plotting, which this lib is based on
found out it's related to the marker type used. this commit did the trick for me loopiezlol/backtrader_plotting@67753b9
I assume "point" or "pixel" would've worked as well, but "dot" doesn't seem to be a valid choice https://matplotlib.org/stable/api/markers_api.html
from btplotting.
@happydasch I'm happy to create a PR trying to fix any invalid matplotlib markers for this repo, but I am curious to learn whether this repo is still maintained beforehand
from btplotting.
from btplotting.
@happydasch and @loopiezlol Thanks for proposing the solution.
Just happened that I uses the same indicator and hitted the same issue.
I gave a try to the solution but the issue still exists. Same as @viveksp, the line plotting looks okay when plotting with the original backtrader plot.
I think the problem is btplotting unable to plot the line / connect the point if the value = NaN
The indicator marks the peak / valley with a value and others are set to NaN. The original backtrader plot is able to connect the point at peak & valley and ignore the NaN in between (just like
https://user-images.githubusercontent.com/3601042/108806710-731b2580-75c8-11eb-889b-07f1c0bdbf08.PNG))
I checked the implemenation of the indicator plotting in backtrader. There's a lineplotinfo._get(_skipnan, False)
check in plot.py (https://github.com/mementum/backtrader/blob/master/backtrader/plot/plot.py#L466)
I wonder does the btplotting apply the same check and consider the "_skipnan" attributes when plotting the line?
I am not familiar with the rendering / plotting code so I cannot help much in this case. Hopefully this can point to the correct solution.
from btplotting.
latest code should be able to plot this, reopen if still not plotting corrrectly
from btplotting.
Related Issues (20)
- The tooltip show too much information. HOT 1
- the candle is not updated in live plotting HOT 1
- Replacing Bokeh with `pyecharts` for better performance HOT 1
- ctype does not match ColumnDataType HOT 1
- ImportError: cannot import name 'Panel' from 'bokeh.models.widgets' HOT 5
- minutes level plotting issue
- cannot import name 'TabPanel' HOT 1
- Live trading ploting got some issuse HOT 5
- The buy/sell arrows are so far away from the candlesticks HOT 1
- The last candle is missing HOT 6
- ImportError: cannot import name 'Panel' from 'bokeh.models.widgets'
- 500:Internal Server Error HOT 2
- ValueError: 'id' cannot be used together with property initializers in Live plotting. HOT 1
- hover info is duplicated in the live mode, any clue? HOT 2
- when changing the filter data, the layout is totally wrong HOT 7
- optimization demo is partially broken? HOT 1
- How to save the html file? HOT 1
- report error when I run `https://github.com/happydasch/btplotting/blob/master/demos/optimization.py` HOT 2
- Chat scaling seems to have a bug
- _skipnan bug HOT 1
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 btplotting.