POSITIONPERF is a function in the ProBuilder language used to calculate the performance of trading positions in terms of percentage gain or loss. This function is particularly useful for traders and analysts to evaluate the effectiveness of their trading strategies over time.
PositionPerf(N)
Where N represents the index of the position for which the performance is calculated:
positionPerformance = PositionPerf(1)
This example calculates the performance of the most recently closed position. The result, positionPerformance, will hold the ratio of gains to the cost of that position, expressed as a percentage.
The POSITIONPERF function does not include brokerage fees in its calculation, which means the performance metrics are gross values. This function is essential for back-testing trading strategies to understand past performance and make informed decisions about future trades.
Understanding the output of POSITIONPERF can help in assessing the risk and return profile of trading strategies, making it a valuable tool for both novice and experienced traders in the ProRealTime trading environment.