feat: Add font_path arg for wordcloud #1598
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This PR is a proposed solution to issue #1466.
The default font in Wordcloud is
DruidSansMono.ttf
, and if the languages of the values are different, the image may be broken.This is a known solution when using wordcloud, but the problem could not be solved because the 'font_path' argument was not specified in ydata_profiling.
I added a setting variable to 'Settings.plot' to pass the value to the font_path argument of word cloud.
Actually, I'm not sure if it's appropriate to put it here.
I just thought that it was a variable for wordcloud plot rendering, and the criterion for judgment was that I thought it could be used in other matplotlib plots as well.
If you do the following, you can check that the wordcloud is displayed normally.