<!--
{
  "availability" : [
    "iOS: 27.0.0 -",
    "iPadOS: 27.0.0 -",
    "tvOS: 27.0.0 -",
    "visionOS: 27.0.0 -",
    "watchOS: 27.0.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "CoreAI",
  "identifier" : "/documentation/CoreAI/InferenceFunction/MutableViews/insert(_:for:)-8ossp",
  "metadataVersion" : "0.1.0",
  "role" : "Instance Method",
  "symbol" : {
    "kind" : "Instance Method",
    "modules" : [
      "Core AI"
    ],
    "preciseIdentifier" : "s:13CoreAIRuntime17InferenceFunctionV12MutableViewsV6insert_3foryAA7NDArrayV0E4ViewVy_xGn_SSts15BitwiseCopyableRzlF"
  },
  "title" : "insert(_:for:)"
}
-->

# insert(_:for:)

Insert the mutable view to be used as the ndArray value named `name`.

```
mutating func insert<Element>(_ mutableView: consuming NDArray.MutableView<Element>, for name: String) where Element : BitwiseCopyable
```

## Parameters

`mutableView`

A mutable view of the ndArray to be used as the value.

`name`

The name of the value that this view should be used for.

---

Copyright &copy; 2026 Apple Inc. All rights reserved. | [Terms of Use](https://www.apple.com/legal/internet-services/terms/site.html) | [Privacy Policy](https://www.apple.com/privacy/privacy-policy)