---
title: "init(x:yStart:yEnd:)"
framework: charts
role: symbol
role_heading: Initializer
path: "charts/areamark/init(x:ystart:yend:)"
---

# init(x:yStart:yEnd:)

Creates an area mark that plots values with a vertical interval.

## Declaration

```swift
nonisolated init<X, Y>(x: PlottableValue<X>, yStart: PlottableValue<Y>, yEnd: PlottableValue<Y>) where X : Plottable, Y : Plottable
```

## Parameters

- `x`: The horizontal position for the mark.
- `yStart`: The starting vertical position for the mark.
- `yEnd`: The ending vertical position for the mark.

## Discussion

Discussion Use this initializer to create a range area chart with vertical intervals. For example you can create a region that encompasses all the temperatures over the course of a day, across a number of days: Chart(data) { day in     AreaMark(         x: .value("Date", day.date),         yStart: .value("Minimum Temperature", minimumTemperature),         yEnd: .value("Maximum Temperature", day.maximumTemperature)     ) }

If you want to plot values that have a horiztonal interval, use init(xStart:xEnd:y:) instead.

## See Also

### Creating a range area chart

- [init(x:yStart:yEnd:series:)](charts/areamark/init(x:ystart:yend:series:).md)
- [init(xStart:xEnd:y:)](charts/areamark/init(xstart:xend:y:).md)
- [init(xStart:xEnd:y:series:)](charts/areamark/init(xstart:xend:y:series:).md)
