Message Boards Message Boards

Packing arbitrary shapes with WordCloud

Posted 5 years ago
POSTED BY: Greg Hurst
3 Replies

enter image description here - Congratulations! This post is now a Staff Pick as distinguished by a badge on your profile! Thank you, keep it coming, and consider contributing your work to the The Notebook Archive!

POSTED BY: Moderation Team
Posted 5 years ago

Hi Chip,

Nice! Are you using version 12? On 11.3.0 for Mac OS X x86 (64-bit) (March 7, 2018) some letters do not discretize

Cases[$letters, _BoundaryDiscretizeGraphics]

{BoundaryDiscretizeGraphics[Text[ Style["h", Italic, FontFamily -> "Times"]], _Text], BoundaryDiscretizeGraphics[Text[ Style["i", Italic, FontFamily -> "Times"]], _Text],
BoundaryDiscretizeGraphics[Text[ Style["j", Italic, FontFamily -> "Times"]], _Text], BoundaryDiscretizeGraphics[Text[ Style["k", Italic, FontFamily -> "Times"]], _Text],
BoundaryDiscretizeGraphics[Text[ Style["y", Italic, FontFamily -> "Times"]], _Text]}

POSTED BY: Rohit Namjoshi

Chip, this is very interesting and useful, thanks for sharing! I would like to add that this is not really working with MM11.3; not that it only has problems with e.g. "i" and "j", the scaling itself does not work. Now that I have updated to MM12 everything is fine. It is nice to know that now there is a fast and easy solution to the packing problem, e.g.:

enter image description here

This reminds me to an old post of mine where I exactly had that problem.

Best regards -- Henrik

POSTED BY: Henrik Schachner
Reply to this discussion
Community posts can be styled and formatted using the Markdown syntax.
Reply Preview
Attachments
Remove
or Discard

Group Abstract Group Abstract