RunMat
  • Pricing
RunMat
GitHub
GitHub
DownloadSign InTry in Browser
DesktopRuntimeServer
RunMat

Run math blazing fast

GitHubX (Twitter)LinkedIn

Company

  • About
  • Pricing
  • Contact

Explore

  • RunMat for academia
  • RunMat vs MATLAB Online
  • Benchmarks

Get product updates and release notes from the RunMat team.

© 2026 Dystr · Made withfor the scientific community.

RunMat™ is a registered trademark of Dystr, Inc. MATLAB® is a registered trademark of The MathWorks, Inc. RunMat is not affiliated with, endorsed by, or sponsored by The MathWorks, Inc.

LicensePrivacy
/
See all docs
Builtin Reference
    • addpoints
    • ancestor
    • animatedline
    • area
    • axes
    • axis
    • bar
    • barh
    • box
    • caxis
    • cla
    • clf
    • clim
    • colorbar
    • colorcube
    • colormap
    • colororder
    • contour
    • contour3
    • contourf
    • copyobj
    • daspect
    • datacursormode
    • dataTipTextRow
    • errorbar
    • fcontour
    • figure
    • fill
    • fill3
    • findobj
    • fsurf
    • gca
    • gcf
    • get
    • gobjects
    • grid
    • groot
    • heatmap
    • hgload
    • hgsave
    • hidden
    • hist
    • histogram
    • histogram2
    • hold
    • image
    • imagesc
    • imshow
    • legend
    • line
    • linkaxes
    • loglog
    • mesh
    • meshc
    • openfig
    • opengl
    • pan
    • parula
    • patch
    • pie
    • plot
    • plot3
    • plotmatrix
    • plotyy
    • polarhistogram
    • polarplot
    • polarscatter
    • print
    • quiver
    • quiver3
    • ribbon
    • saveas
    • savefig
    • scatter
    • scatter3
    • semilogx
    • semilogy
    • set
    • sgtitle
    • shading
    • sphere
    • stackedplot
    • stairs
    • stem
    • subplot
    • subtitle
    • suptitle
    • surf
    • surfc
    • text
    • textscatter
    • textscatter3
    • title
    • triplot
    • view
    • waitbar
    • wordcloud
    • xlabel
    • xlim
    • xline
    • xscale
    • xtickangle
    • xtickformat
    • xticklabels
    • xticks
    • ylabel
    • ylim
    • yline
    • yscale
    • ytickangle
    • ytickformat
    • yticklabels
    • yticks
    • zlabel
    • zlim
    • zoom

wordcloud — Create a word cloud chart from text, tokenized documents, bag models, categorical arrays, tables, or word-size data.

wordcloud creates a WordCloudChart handle from raw text, tokenized documents, bag models, categorical arrays, explicit word sizes, or table variables.

Syntax

wc = wordcloud(str)
wc = wordcloud(documents)
wc = wordcloud(bag)
wc = wordcloud(words, sizeData)
wc = wordcloud(tbl, wordVar, sizeVar)
wc = wordcloud(C)
wc = wordcloud(parent, ...)
wc = wordcloud(..., Name, Value)

Inputs

NameTypeRequiredDefaultDescription
dataAnyYes—Text, tokenizedDocument, bag model, categorical array, or LDA model.
wordsAnyYes—Word vector.
sizeDataNumericArrayYes—Word size vector.
tblAnyYes—Table with word and size variables.
wordVarAnyYes—Table variable containing words.
sizeVarAnyYes—Table variable containing word sizes.
NameValueAnyVariadic—WordCloudChart name-value properties.

Returns

NameTypeDescription
wcNumericScalarHandle to the WordCloudChart object.

Errors

IdentifierWhenMessage
RunMat:wordcloud:InvalidArgumentInput data, table selectors, parent axes, or WordCloudChart properties are invalid.wordcloud: invalid argument
RunMat:wordcloud:InternalInternal plotting state update fails while creating or mutating a word cloud.wordcloud: internal operation failed

How wordcloud works

  • wordcloud(str) tokenizes string, character, string-array, or cellstr input, removes common English stop words, counts words, and renders the most frequent words.
  • wordcloud(documents) accepts tokenizedDocument objects and counts tokens from their Documents property.
  • wordcloud(bag) accepts bagOfWords and bagOfNgrams objects and sums each column of Counts; n-gram labels are joined with spaces.
  • wordcloud(words,sizeData) accepts a word vector and a numeric vector with the same element count. The compatibility target documents all eight native integer classes for sizeData; RunMat reads them from native storage before entering the chart's floating size domain. Duplicate words are aggregated and zero-sized entries are omitted.
  • wordcloud(tbl,wordVar,sizeVar) accepts table and timetable objects where wordVar and sizeVar are variable names or scalar variable indices. Numeric selectors may use any native integer class and are decoded exactly as one-based structural indices.
  • wordcloud(C) accepts categorical objects and uses category counts as word sizes.
  • A leading encoded numeric figure or axes handle is a RunMat language extension available in runmat mode. The selected figure's active axes receives the chart.
  • Supported name-value options are MaxDisplayWords, Color, HighlightColor, Shape (oval or rectangle), LayoutNum, SizePower, Title, TitleFontName, Visible, FontName, Box, Units, Position, HandleVisibility, DisplayName, and Tag.
  • Native integer storage for numeric chart properties such as MaxDisplayWords and LayoutNum is a RunMat language extension available in runmat mode. Ordinary integer-valued doubles remain available in MATLAB-compatible modes.
  • MaxDisplayWords is capped at 1000 rendered annotation slots to keep chart creation bounded.
  • get supports Type, Parent, Children, WordData, SizeData, WordVariable, SizeVariable, SourceTable, MaxDisplayWords, Color, HighlightColor, Shape, LayoutNum, SizePower, Title, TitleFontName, FontName, Visible, Box, Units, Position, HandleVisibility, DisplayName, and Tag.
  • set supports WordData, SizeData, MaxDisplayWords, Color, HighlightColor, Shape, LayoutNum, SizePower, Title, TitleFontName, FontName, Visible, Box, Units, Position, HandleVisibility, DisplayName, and Tag; WordData and SizeData assignments must preserve matching lengths.
  • RunMat uses a deterministic annotation layout rather than attempting to reproduce another renderer's placement algorithm. FontName, TitleFontName, Units, Position, and HandleVisibility are stored as chart metadata; the current plotting renderer does not yet expose a separate chart-container layout or font-family path. LDA topic word clouds remain unsupported until ldaModel support exists.

Examples

Create a word cloud from text

txt = "runmat computes fast math and runmat plots math";
wc = wordcloud(txt);

Create a word cloud from explicit word sizes

words = ["alpha" "beta" "gamma"];
sizes = [5 9 2];
wc = wordcloud(words, sizes, 'MaxDisplayWords', 2, 'Shape', 'rectangle');
get(wc, 'WordData')

Create a word cloud from a table

tbl = table(["alpha";"beta"], [10;4], 'VariableNames', {'Word','Count'});
wc = wordcloud(tbl, 'Word', 'Count');

Using wordcloud with coding agents

Open a RunMat example with live inputs, then ask the agent to explain how wordcloud changes the result.

Run a small wordcloud example, explain the result, then change one input and compare the output.

FAQ

Does wordcloud return a graphics object?⌄

Yes. RunMat returns a first-class wordcloud chart handle with readable and mutable chart properties through get and set.

Does RunMat match MATLAB's exact word placement?⌄

No. RunMat computes compatible word labels, sizes, and chart properties, then uses its own deterministic annotation layout.

Can wordcloud preserve gpuArray residency?⌄

No. Word clouds are host chart-rendering sinks over text, table, categorical, and bag metadata. Explicit gpuArray input is not supported.

Related Plotting functions

2D Charts

area · bar · errorbar · heatmap · hist · histogram · loglog · pie · plot · scatter · semilogx · semilogy · stairs · stem

3D & Surface

contour · contour3 · contourf · mesh · meshc · plot3 · quiver · scatter3 · surf · surfc

Images

image · imagesc · imshow

Axes & Layout

axis · box · grid · sgtitle · subplot · title · view · zlabel

Appearance

colorbar · colormap · legend · shading

Handle Access

gca · gcf · get · set

Other

addpoints · ancestor · animatedline · axes · barh · caxis · cla · clf · clim · colorcube · colororder · copyobj · daspect · datacursormode · dataTipTextRow · fcontour · figure · fill · fill3 · findobj · fsurf · gobjects · groot · hgload · hgsave · hidden · histogram2 · hold · line · linkaxes · openfig · opengl · pan · parula · patch · plotmatrix · plotyy · polarhistogram · polarplot · polarscatter · print · quiver3 · ribbon · saveas · savefig · sphere · stackedplot · subtitle · suptitle · text · textscatter · textscatter3 · triplot · waitbar · xlabel · xlim · xline · xscale · xtickangle · xtickformat · xticklabels · xticks · ylabel · ylim · yline · yscale · ytickangle · ytickformat · yticklabels · yticks · zlim · zoom

More plotting resources

  • MATLAB language extensions

Open-source implementation

Unlike proprietary runtimes, every RunMat function is open-source. Read exactly how wordcloud is executed, line by line, in Rust.

  • View the source for wordcloud in Rust on GitHub
  • Learn how the RunMat runtime works
  • Found a bug? Open an issue with a minimal reproduction.

About RunMat

RunMat is an open-source runtime that executes MATLAB-syntax code blazing on any GPU. It is licensed under the Apache 2.0 license.

  • RunMat automatically optimizes your math for GPU execution on Apple, Nvidia, and AMD hardware. No code changes needed. Simulations that took hours now take minutes.
  • Start running code in seconds. RunMat runs in the browser, on the desktop, or from the CLI. No license server, no IT ticket.

Getting started · Benchmarks · Pricing

Download RunMat

Download RunMat for full performance, or use RunMat in your browser for zero setup.

Download RunMatOpen Sandbox
On this page
  • Syntax
  • Inputs
  • Returns
  • Errors
  • How wordcloud works
  • Examples
  • Create a word cloud from text
  • Create a word cloud from explicit word sizes
  • Create a word cloud from a table
  • Using wordcloud with coding agents
  • FAQ
  • Related Plotting functions
  • 2D Charts
  • 3D & Surface
  • Images
  • Axes & Layout
  • Appearance
  • Handle Access
  • Other
  • More plotting resources
  • Open-source implementation
  • About RunMat