3444430a2a1488de3b96249e363ff4a8aab8a5dd,examples/over-sampling/plot_comparison_over_sampling.py,,,#,109

Before Change


// approach the boundary decision is already less biaised toward the majority
// class.

fig, (ax1, ax2) = plt.subplots(1, 2, figsize=(15, 7))
X, y = create_dataset(n_samples=10000, weights=(0.01, 0.05, 0.94))
clf = LinearSVC().fit(X, y)
plot_decision_function(X, y, clf, ax1)

After Change


// to generate a smoothed bootstrap instead. The plot below shows the difference
// between the two data generation strategies.

fig, axs = plt.subplots(1, 2, figsize=(15, 7))
sampler = RandomOverSampler(random_state=0)
plot_resampling(X, y, sampler, ax=axs[0])
axs[0].set_title("RandomOverSampler with normal bootstrap")
sampler = RandomOverSampler(smoothed_bootstrap=True, shrinkage=0.2, random_state=0)
Italian Trulli
In pattern: SUPERPATTERN

Frequency: 3

Non-data size: 5

Instances


Project Name: scikit-learn-contrib/imbalanced-learn
Commit Name: 3444430a2a1488de3b96249e363ff4a8aab8a5dd
Time: 2021-02-12
Author: g.lemaitre58@gmail.com
File Name: examples/over-sampling/plot_comparison_over_sampling.py
Class Name:
Method Name:


Project Name: scikit-learn-contrib/imbalanced-learn
Commit Name: 71b1e873e70dca43cd12870d4c0f497015f41970
Time: 2021-02-17
Author: g.lemaitre58@gmail.com
File Name: examples/datasets/plot_make_imbalance.py
Class Name:
Method Name:


Project Name: matplotlib/matplotlib
Commit Name: ac69b1035a42e47798e4ea7167f616754be49452
Time: 2020-05-01
Author: toddrjen@gmail.com
File Name: examples/ticks_and_spines/tick-formatters.py
Class Name:
Method Name: