AvgLongFirstDayLabel := label.new(bar_index, low - 10, text = "出现做多信号之后X天可以盈利:" + str.tostring(LongAvgFirstDay), style=label.style_label_up, color=color.rgb(255, 110, 110), size=size.normal)
I wrote a strategy and calculated the value of “the first profit can be made on X day after the long signal appears”. Now I use a label to display this label on the last K line.
I want this value to be displayed in the “Performance Summary” in the form of “Performance Summary”. For example: I have now separately counted short and long positions (all can also be calculated), assuming the title is: Xth time after XX signal appears I can make a profit for the first time after a few days. Is there any method (you can also refer to the documentation) or what code I need to add to pineStrict to make the “Performance Summary” additionally display my own data?
When I used python’s pandas library before, I often used “A = pd.DataFrame()” and then “A.to_csv()”, but now I have migrated to tradingview due to work needs. I also want to add custom data and How should I export this data to CSV in the “Transaction List” format?
Thanks for everyone’s answers
jacky is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.