Difference between revisions of "Array Indices and XY Functions"

From ZCubes Wiki
Jump to navigation Jump to search
Line 40: Line 40:
  
 
Similar to atindex, but just to get the node indices.
 
Similar to atindex, but just to get the node indices.
 +
 +
[[Array.indexanddata(SomeFunction,SubtractByArray,ScaleByArray,DoNotShowIndices,SomeRowArray)]]
 +
 +
Applies the functions to every element. For each element, the function is passed with indices of the element, and value of the element. Use DoNotShowIndices to hide indices with result.
 +
 +
For internal use only.
  
 
[[Array.indicesCore()]]
 
[[Array.indicesCore()]]
  
 
For internal use only.
 
For internal use only.

Revision as of 19:35, 29 July 2024

These functions operate on array locations and values to create contours and other interesting operations.

Array.indices()

Parameters: Function,SubtractByArray,ScaleByArray,DoNotShowIndices,RowArray

Function is applied to array indices at each array location scaled by Scale Array, with SubtractByArray subtracted. Indices can be avoided in output with DoNotShowIndices parameter. RowArray can filter the output.

Array.xy()

Parameters: (Function, OffsetArray, ScaleArray,GiveIndicesAlso,DoCentering) Similar to .indices but gives the indices only if GiveIndicesAlso is asked for.


Array.xypanel()

Similar to .xy but with DoCentering as default.

Array.applyat()


Similar to .indices but uses the value at the cell location.

Old name was: Array.at() which is now https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array/at


Array.atnode()

Similar to .indices, but just to get the node value.

Array.atindex()

Gets nodes from the indices mentioned.

Array.nodeindex()

Similar to atindex, but just to get the node indices.

Array.indexanddata(SomeFunction,SubtractByArray,ScaleByArray,DoNotShowIndices,SomeRowArray)

Applies the functions to every element. For each element, the function is passed with indices of the element, and value of the element. Use DoNotShowIndices to hide indices with result.

For internal use only.

Array.indicesCore()

For internal use only.