view(as:)
Returns a read-only, typed view of this array’s elements.
Declaration
func view<T>(as type: T.Type = T.self) -> NDArray.View<T> where T : BitwiseCopyableParameters
- type:
The Swift type that corresponds to this array’s Scalartype Swift.property. For example, pass
Int32.selffor an array with scalar type.int32.
Return Value
A read-only view of the array’s elements.