<!--
{
  "availability" : [
    "iOS: 18.0.0 -",
    "iPadOS: 18.0.0 -",
    "macCatalyst: 18.0.0 -",
    "macOS: 15.0.0 -",
    "tvOS: 18.0.0 -",
    "visionOS: 2.0.0 -",
    "watchOS: 11.0.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "Charts",
  "identifier" : "/documentation/Charts/SectorPlot",
  "metadataVersion" : "0.1.0",
  "role" : "Structure",
  "symbol" : {
    "kind" : "Structure",
    "modules" : [
      "Swift Charts"
    ],
    "preciseIdentifier" : "s:6Charts10SectorPlotV"
  },
  "title" : "SectorPlot"
}
-->

# SectorPlot

Chart content that represents a collection of data using a sector of a pie or donut chart,
which shows how individual categories make up a meaningful total.

```
struct SectorPlot<Content>
```

## Overview

Use `SectorPlot` when you want to visualize data in the same way as with [`SectorMark`](/documentation/Charts/SectorMark),
but you want to visualize an entire data collection with a single plot.

You can initialize and style the plot with simple values or key paths.
Add modifiers with `KeyPath` before adding modifiers with simple values.

```
SectorPlot(
    votes,
    angle: .value("Vote count", \.voteCount),
    angularInset: 1
)
.foregroundStyle(by: .value("Party", \.party))
.cornerRadius(4)
```

## Topics

### Plotting sectors from a collection

[`init(_:angle:innerRadius:outerRadius:angularInset:)`](/documentation/Charts/SectorPlot/init(_:angle:innerRadius:outerRadius:angularInset:)-1ed01)

[`init(_:angle:innerRadius:outerRadius:angularInset:)`](/documentation/Charts/SectorPlot/init(_:angle:innerRadius:outerRadius:angularInset:)-9pmo7)

### Supporting types

[`body`](/documentation/Charts/ChartContent/body-swift.property)

The content and behavior of the chart content.

[`VectorizedSectorPlotContent`](/documentation/Charts/VectorizedSectorPlotContent)

An opaque vectorized chart content type.



---

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)