PINE LIBRARY
업데이트됨 ArrayGenerate

Library "ArrayGenerate"
Functions to generate arrays.
sequence_int(start, end, step) returns a sequence of int numbers.
Parameters:
Returns: int[], array.
sequence_float(start, end, step) returns a sequence of float numbers.
Parameters:
Returns: float[], array.
sequence_from_series(src, length, shift, direction_forward) Creates a array from a series sample range.
Parameters:
Returns: float array
normal_distribution(size, mean, dev) Generate normal distribution random sample.
Parameters:
Returns: float array.
log_spaced(length, start_exp, stop_exp) Generate a base 10 logarithmically spaced sample sequence.
Parameters:
Returns: float array.
linear_range(stop, start) Generate a linearly spaced sample vector within the inclusive interval (start, stop) and step 1.
Parameters:
Returns: float array.
periodic_wave(length, sampling_rate, frequency, amplitude, phase, delay) Create a periodic wave.
Parameters:
Returns: float array.
sinusoidal(length, sampling_rate, frequency, amplitude, mean, phase, delay) Create a Sine wave.
Parameters:
Returns: float array.
periodic_impulse(length, period, amplitude, delay) Create a periodic Kronecker Delta impulse sample array.
Parameters:
Returns: float array.
Functions to generate arrays.
sequence_int(start, end, step) returns a sequence of int numbers.
Parameters:
- start: int, begining of sequence range.
- end: int, end of sequence range.
- step: int, step, default=1 .
Returns: int[], array.
sequence_float(start, end, step) returns a sequence of float numbers.
Parameters:
- start: float, begining of sequence range.
- end: float, end of sequence range.
- step: float, step, default=1.0 .
Returns: float[], array.
sequence_from_series(src, length, shift, direction_forward) Creates a array from a series sample range.
Parameters:
- src: series, any kind.
- length: int, window period in bars to sample series.
- shift: int, window period in bars to shift backwards the data sample, default=0.
- direction_forward: bool, sample from start to end or end to start order, default=true.
Returns: float array
normal_distribution(size, mean, dev) Generate normal distribution random sample.
Parameters:
- size: int, size of array
- mean: float, mean of the sample, (default=0.0).
- dev: float, deviation of the sample from the mean, (default=1.0).
Returns: float array.
log_spaced(length, start_exp, stop_exp) Generate a base 10 logarithmically spaced sample sequence.
Parameters:
- length: int, length of the sequence.
- start_exp: float, start exponent.
- stop_exp: float, stop exponent.
Returns: float array.
linear_range(stop, start) Generate a linearly spaced sample vector within the inclusive interval (start, stop) and step 1.
Parameters:
- stop: float, stop value.
- start: float, start value, (default=0.0).
Returns: float array.
periodic_wave(length, sampling_rate, frequency, amplitude, phase, delay) Create a periodic wave.
Parameters:
- length: int, the number of samples to generate.
- sampling_rate: float, samples per time unit (Hz). Must be larger than twice the frequency to satisfy the Nyquist criterion.
- frequency: float, frequency in periods per time unit (Hz).
- amplitude: float, the length of the period when sampled at one sample per time unit. This is the interval of the periodic domain, a typical value is 1.0, or 2*Pi for angular functions.
- phase: float, optional phase offset.
- delay: int, optional delay, relative to the phase.
Returns: float array.
sinusoidal(length, sampling_rate, frequency, amplitude, mean, phase, delay) Create a Sine wave.
Parameters:
- length: int, The number of samples to generate.
- sampling_rate: float, Samples per time unit (Hz). Must be larger than twice the frequency to satisfy the Nyquist criterion.
- frequency: float, Frequency in periods per time unit (Hz).
- amplitude: float, The maximal reached peak.
- mean: float, The mean, or DC part, of the signal.
- phase: float, Optional phase offset.
- delay: int, Optional delay, relative to the phase.
Returns: float array.
periodic_impulse(length, period, amplitude, delay) Create a periodic Kronecker Delta impulse sample array.
Parameters:
- length: int, The number of samples to generate.
- period: int, impulse sequence period.
- amplitude: float, The maximal reached peak.
- delay: int, Offset to the time axis. Zero or positive.
Returns: float array.
릴리즈 노트
v2 - Update to V6.파인 라이브러리
트레이딩뷰의 진정한 정신에 따라, 작성자는 이 파인 코드를 오픈소스 라이브러리로 게시하여 커뮤니티의 다른 파인 프로그래머들이 재사용할 수 있도록 했습니다. 작성자에게 경의를 표합니다! 이 라이브러리는 개인적으로 사용하거나 다른 오픈소스 게시물에서 사용할 수 있지만, 이 코드의 게시물 내 재사용은 하우스 룰에 따라 규제됩니다.
면책사항
해당 정보와 게시물은 금융, 투자, 트레이딩 또는 기타 유형의 조언이나 권장 사항으로 간주되지 않으며, 트레이딩뷰에서 제공하거나 보증하는 것이 아닙니다. 자세한 내용은 이용 약관을 참조하세요.
파인 라이브러리
트레이딩뷰의 진정한 정신에 따라, 작성자는 이 파인 코드를 오픈소스 라이브러리로 게시하여 커뮤니티의 다른 파인 프로그래머들이 재사용할 수 있도록 했습니다. 작성자에게 경의를 표합니다! 이 라이브러리는 개인적으로 사용하거나 다른 오픈소스 게시물에서 사용할 수 있지만, 이 코드의 게시물 내 재사용은 하우스 룰에 따라 규제됩니다.
면책사항
해당 정보와 게시물은 금융, 투자, 트레이딩 또는 기타 유형의 조언이나 권장 사항으로 간주되지 않으며, 트레이딩뷰에서 제공하거나 보증하는 것이 아닙니다. 자세한 내용은 이용 약관을 참조하세요.