SetIndicatorIdKey
Sets a unique identifier key for the indicator.
Syntax
SetIndicatorIdKey(key: string): void
Parameters
key
- A string containing a unique identifier for the indicator.
Return Value
This method does not return a value.
Description
The SetIndicatorIdKey
method assigns a unique identifier key to the indicator. This key can be used for internal reference, persistence, or to identify the indicator in various operations.
Example
// Set a simple key
this.api.SetIndicatorIdKey('RSI_14')
// Use a more complex key with parameters
this.api.SetIndicatorIdKey(`MA_${period}_${method}_${price}`)
// Generate a unique key
this.api.SetIndicatorIdKey(`CustomIndicator_${Date.now()}`)
Last updated