Reputation: 23
I am trying to automate a simple strategy based on discretionary placement of trendlines. Ideally what I would want is place two lines manually on a chart and then interact with these lines in a pine script. For that I would need to be able to retrieve the line IDs of existing objects on the chart (or selected objects maybe?). I can't seem to find anywhere how to do this, or if at all possible.
The opposite would also be acceptable, meaning the script would place two lines on the chart using default values and the user would be able to move these around the chart so that the script can then get their coordinates afterwards.
It that at all possible? If so any documentation or reference would be very appreciated.
Upvotes: 2
Views: 593
Reputation: 6885
This cannot be done in Pine, because Pine does not allow for interaction with manually drawn objects, nor does it allow lines generated by Pine to be changed manually by the user.
Upvotes: 2