-
Notifications
You must be signed in to change notification settings - Fork 260
Stock graph with a combined horizontal line at a specific price? #30
Comments
Yes, it is possible and its achieved by just combining text, line, and StockLine components in a single view. I took the example app included in this project, isolated the StockLine chart, gave it a shot:
and I tweaked the options data for the chart in data.js:
and I came up with this: |
@marzolfb Thanks! I see that the position of these labels are 'absolute' and not related to the chart value? How can I know for example that the 253453 value is at top:70? I was expecting for a way to specify the Y position of the line using the Y-axis values. Any ideas on this? Thanks again! |
Thats a fair critique of the solution I offer above. Perhaps a better strategy is to use all react-native-svg components to show the line and text - i.e. replace the react native If you do get something worked out and are willing to add an option to toggle showing the line and label to the existing StockLine chart, I think it would make a great addition to the library and I would welcome a PR for it. |
Thanks, I will have a look in the next days and will let you know of my findings. |
Thanks for your great library!
I am not sure if (how) this "combination" of a line chart with a "horizontal" line is possible:
Is this possible somehow with the library?
Thank you for any insights you can provide.
The text was updated successfully, but these errors were encountered: