Burcu İçen
Burcu İçen

Reputation: 155

How can i give Gaussian noise to my moons dataset with a deviation value of 0.2 in python?

I have make_moons dataset, generated by scikit-learn

X, y = make_moons(n_samples=120)

How can i give Gaussian noise to my moons dataset with a deviation value of 0.2 in python?

Upvotes: 0

Views: 205

Answers (1)

Matus Dubrava
Matus Dubrava

Reputation: 14462

You can just pass that value to the make_moons function as noise.

x, y = make_moons(n_samples=120, noise=0.2)

noise : double or None (default=None) Standard deviation of Gaussian noise added to the data.

Upvotes: 1

Related Questions