TradingView
RicardoSantos
27 Eki 2021 15:47

ArrayMultipleDimensionPrototype 

US Nas 100OANDA

Açıklama

Library "ArrayMultipleDimensionPrototype"
A prototype library for Multiple Dimensional array methods

index_md_to_1d()

new_float(dimensions, initial_size) Creates a variable size multiple dimension array.
  Parameters:
    dimensions: int array, dimensions of array.
    initial_size: float, default=na, initial value of the array.
  Returns: float array

dimensions(id, value) set value of a element in a multiple dimensions array.
  Parameters:
    id: float array, multiple dimensions array.
    value: float, new value.
  Returns: float.

get(id) get value of a multiple dimensions array.
  Parameters:
    id: float array, multiple dimensions array.
  Returns: float.

set(id) set value of a element in a multiple dimensions array.
  Parameters:
    id: float array, multiple dimensions array.
  Returns: float.
Yorumlar
X3EM
Hey Santos. Great work! Q: I need to sort array like this by Price and later after mods by Index
(index:1, PivotDateTime:”1/2/2023”, Price:”3.2232”,PivotType:”High” ),
(index:2, PivotDateTime:”1/2/2022”, Price:”1.2232”,PivotType:”Low” ),
(index:3, PivotDateTime:”3/16/2022”, Price:”1.543”,PivotType:”High” ),
And also would love to export array into CSV string so I can copy it (don't have premium)
I see ur array only accepts floats
Any suggestions? thanks
SonicShi
Thanks for posting!Cool man
jcastilla358
very cool. Would it be possible to put some simple examples for practical use? @RicardoSantos
Duyck
Nice twist with the var dims!!

Gr, JD.
Mihai_Iacob
Thanks for posting
Daha Fazla