fuzzyclust.models.make_sinc#

fuzzyclust.models.make_sinc(n_samples=200, noise=0.02, n_features=1, random_state=None)[source]#

Samples of the sinc function, the classic static benchmark of fuzzy modeling.

\[y = \frac{\sin x}{x}\quad (n=1),\qquad y = \frac{\sin x_1}{x_1}\,\frac{\sin x_2}{x_2}\quad (n=2),\]

with \(x_j\) drawn uniformly from \([-10, 10]\) and additive Gaussian noise of standard deviation noise.

Parameters:
n_samplesint, default=200
noisefloat, default=0.02
n_features{1, 2}, default=1
random_stateint, RandomState instance or None, default=None
Returns:
Xndarray of shape (n_samples, n_features)
yndarray of shape (n_samples,)

Examples

>>> from fuzzyclust.models import make_sinc
>>> X, y = make_sinc(n_samples=50, random_state=0)
>>> X.shape, y.shape
((50, 1), (50,))

Examples using fuzzyclust.models.make_sinc#

Subtractive clustering: the number and location of clusters from density

Subtractive clustering: the number and location of clusters from density

Takagi–Sugeno model of a static nonlinearity: clusters become rules

Takagi–Sugeno model of a static nonlinearity: clusters become rules