File tree Expand file tree Collapse file tree 1 file changed +5
-0
lines changed Expand file tree Collapse file tree 1 file changed +5
-0
lines changed Original file line number Diff line number Diff line change 4343ax .add_artist (class_legend )
4444ax .set_xlabel ("Feature #1" )
4545_ = ax .set_ylabel ("Feature #2" )
46+ plt .tight_layout ()
4647
4748# %%
4849# Now, we will use a :class:`~imblearn.over_sampling.RandomOverSampler` to
6162ax .add_artist (class_legend )
6263ax .set_xlabel ("Feature #1" )
6364_ = ax .set_ylabel ("Feature #2" )
65+ plt .tight_layout ()
6466# %%
6567# We observe that the minority samples are less transparent than the samples
6668# from the majority class. Indeed, it is due to the fact that these samples
7981ax .add_artist (class_legend )
8082ax .set_xlabel ("Feature #1" )
8183_ = ax .set_ylabel ("Feature #2" )
84+ plt .tight_layout ()
8285
8386# %%
8487# In this case, we see that the samples in the minority class are not
97100ax .add_artist (class_legend )
98101ax .set_xlabel ("Feature #1" )
99102_ = ax .set_ylabel ("Feature #2" )
103+ plt .tight_layout ()
100104
101105# %%
102106# Increasing the value of `shrinkage` will disperse the new samples. Forcing
112116ax .add_artist (class_legend )
113117ax .set_xlabel ("Feature #1" )
114118_ = ax .set_ylabel ("Feature #2" )
119+ plt .tight_layout ()
115120
116121# %%
117122# Therefore, the `shrinkage` is handy to manually tune the dispersion of the
You can’t perform that action at this time.
0 commit comments