PINE LIBRARY

StrTrimPadCase

OVERVIEW

Contains various functions for manipulation with strings:

- padright() / padleft() - Pad a string to the right or left with a given char.

- trim2() - Trims not only spaces but also line breaks.

- nz(string) - like nz(), replaces na with a supplied string

FUNCTIONS

nz(s, replacement)
  Similar to nz() but for strings. However, since `string(na)` is the same as `""`
there is no such thing as `na` for strings. So, the function just replaces `""` with `replacement`.
  Parameters:
    s (string)
    replacement (string): (string) (Optional) A string returned when `s` is `""` / `na`. Default: `""`

method toUppercase(s)
  Converts a string to uppercase
  Namespace types: series string, simple string, input string, const string
  Parameters:
    s (string)

method toLowercase(s)
  Converts a string to uppercase
  Namespace types: series string, simple string, input string, const string
  Parameters:
    s (string)

method padright(this, length, char)
  pads a string up to `length` by adding `char`'s (spaces by default) to the end. (the first char of `char`
string is used). Respects max string length of 4096.
  Namespace types: series string, simple string, input string, const string
  Parameters:
    this (string)
    length (int)
    char (simple string): (string) A char to pad with. (if string longer than one char is supplied uses the first char)

method padleft(this, length, char)
  pads a string up to `length` by adding `char`'s (spaces by default) to the beginning(the first char of
`char` string is used). Respects max string length of 4096.
  Namespace types: series string, simple string, input string, const string
  Parameters:
    this (string)
    length (int)
    char (simple string): (string) A char to pad with. (if string longer than one char is supplied uses the first char)
stringstrings

Pineライブラリ

TradingViewの精神に則り、作者はPineコードをオープンソースライブラリとして公開し、コミュニティの他のPineプログラマーが再利用できるようにしました。作者に敬意を表します!このライブラリを個人的に、または他のオープンソースの投稿で使用することができますが、このコードを投稿で再利用するには、ハウスルールに準拠する必要があります。

免責事項