---
title: samplingMethod
framework: metalperformanceshadersgraph
role: symbol
role_heading: Instance Property
path: metalperformanceshadersgraph/mpsgraphrandomopdescriptor/samplingmethod
---

# samplingMethod

The sampling method of the distribution.

## Declaration

```swift
var samplingMethod: MPSGraphRandomNormalSamplingMethod { get set }
```

## Discussion

Discussion This value is used for Normal and Truncated Normal disributions. See MPSGraphRandomNormalSamplingMethod. Defaults to MPSGraphRandomNormalSamplingInvCDF.
