TradingView
keio
2 de Abr de 2022 18:43

console 

Bitcoin / TetherUS PERPETUAL CONTRACTBinance

Descrição

Library "console"
Simple debug console to print messages from your strategy code.

USAGE :
  • Make sure your strategy overlay is false
  • Import the library :

import keio/console/1 as console

init(lines, panes)
Initialise function.

USAGE :
var log = console.init()

  Parameters:
    lines: Optional. Number of lines to display
    panes: Optional. Number of panes to display

  Returns: initialised log

print(log)
Prints a message to the console.

USAGE :
log := console.print(log, "message")

  Parameters:
    log: Mandatory. The log returned from the init() function
  Returns: The log

Notas de Lançamento

Bug fixes.

INSTRUCTIONS BELOW
Comentários
LucasVivien
Hey Keio, thanks for the script!
Are you planning on adding new functionalities, maybe some some user input?
Looking forward ;)
keio
Hey @LucasVivien, thank you for the suggestion.
Unfortunately I haven't found a way to use user inputs inside libraries yet : (
I've updated the script to version 2 though, and added an example on how to use it ; )
LucasVivien
@keio, True for user input, my bad.
I'll have a look at V2. Thx
Mais