<!--
{
  "availability" : [
    "iOS: 27.0.0 -",
    "iPadOS: 27.0.0 -",
    "macCatalyst: 27.0.0 -",
    "macOS: 27.0.0 -",
    "visionOS: 27.0.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "PencilKit",
  "identifier" : "/documentation/PencilKit/PKStrokePathReference/subpath(with:)",
  "metadataVersion" : "0.1.0",
  "role" : "Instance Method",
  "symbol" : {
    "kind" : "Instance Method",
    "modules" : [
      "PencilKit"
    ],
    "preciseIdentifier" : "c:objc(cs)PKStrokePath(im)subpathWithRange:"
  },
  "title" : "subpath(with:)"
}
-->

# subpath(with:)

Returns a copy of the path containing the control points in the specified parametric range.

```
func subpath(with range: __PKFloatRange) -> PKStrokePath
```

## Parameters

`range`

The parametric range to copy. Values must be within [0, count-1].

## Return Value

A new stroke path containing the portion within the specified parametric range.

---

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)