Hot answers tagged

21 votes
Accepted

How to type text with an underbrace underneath it like: $\underbrace{g...g}_{n-times}$?

You want to use an UnderBrace. Highlight the g....g then type Ctrl-4 to get under it, then type Esc ...
Jason B.'s user avatar
  • 67k
17 votes

Skip header lines on import

The Import command supports an option to ignore header lines. In many cases this is the easiest solution. For example: ...
Tyler Durden's user avatar
  • 4,048
16 votes

Is there a convenient way to copy/paste text-interspersed SE code snippets into Mathematica?

I posted a possible answer for this on meta (Download questions or chats for offline reading), but perhaps it belongs here on the main site instead. I have a paclet that downloads a stack exchange ...
Carl Woll's user avatar
  • 129k
16 votes
Accepted

What stopwords list is the Wolfram language using?

A little spelunking of the code for DeleteStopwords[] yields the internally used stopword list: ...
J. M.'s lack of A.I.'s user avatar
15 votes

How can I wrap text around a circle?

My solution, which does not try to place the letters, but rather transform the space they inhabit. This has an extra feature/bug/property that parallel lines in the letters may no longer be parallel ...
user1747134's user avatar
15 votes

What stopwords list is the Wolfram language using?

The stop-words are documented and can be looked up as (see Details section of WordList): WordList["Stopwords"] As it might be ...
Vitaliy Kaurov's user avatar
15 votes
Accepted

Can this effect be achieved with Mathematica?

Here is an approach using some basics of object-oriented programming. Load the lyrics: ...
Vly's user avatar
  • 388
13 votes
Accepted

ROT13 and upside-down text (flip text)

1. ROT13 ...
rhermans's user avatar
  • 35.8k
12 votes
Accepted

Using Padding with Text and Style

There are two alternatives I would suggest, depending on what your plans for the Background are. Here is an illustration: ...
Jens's user avatar
  • 96.6k
12 votes

Is there a way to outline text?

In version 10, we can bypass exporting to PDF and re-importing and can outline text directly using region discretization functions. This is shown in the documentation of ...
Szabolcs's user avatar
  • 232k
12 votes
Accepted

How to type sentences into Mathematica

(J.M.'s comment) You can select a cell and do Format > Style > Text, or you can directly right-click on a cell bracket, or you can convert or generate a new text cell by the keyboard shortcut Alt+7....
12 votes
Accepted

Qubit passing through quantum gate animation

Perhaps something like this? ...
WReach's user avatar
  • 68.3k
12 votes

Implementing a Better Grep Command

Mathematica allows text searching using regular expressions (based on the PCRE library). It would take some work to re-implement the whole grep functionality within ...
Alexey Popkov's user avatar
12 votes
Accepted

How to write graffiti, i.e., text on a polygon surface in Graphics3D?

I would take a look at the Wolfram-U video for Advanced 3D Graphics in the Wolfram Language and download the notebook. Look at slide 22 and the billboard3D ...
Tim Laska's user avatar
  • 16.2k
11 votes
Accepted

Highlighting pattern strings in a large text

There is another way that is on my machine almost 500x faster then your solution. The idea is to look how Mathematica represents colored strings and use this directly. When we colorize an input ...
halirutan's user avatar
  • 112k
11 votes
Accepted

How to remove unknown zero-width character from string?

You can see the zero-width character using FullForm: str //FullForm "\:200b\:200b4-6" So, in this case, you can use the following: ...
Carl Woll's user avatar
  • 129k
11 votes
Accepted

How to place PlotLabel inside the plot frame

Use scaled coordinates Scaled[{x,y}] for easier control. Scale runs $0<(x,y)<1$ independently of actual axes values, ...
Vitaliy Kaurov's user avatar
11 votes

Wolfram Neural Net Repository Questions

I believe I'm a heavy user of the neural network framework and the Wolfram Neural Network Repository(WNNR) and these are how I see the WNNR from a user's perspective. Hope it will be helpful. First of ...
xslittlegrass's user avatar
10 votes
Accepted

Accessing figure style (oldstyle or lining) of TrueType fonts

These issues are unfortunately OS- and font family-dependent, so I will preface that I am working on Windows 7 - 64 bit using MMA 10.2. I currently don't have the Aller font installed on my machine, ...
MarcoB's user avatar
  • 65.3k
10 votes
Accepted

WordCloud: can words' style and orientation be functions of words?

WordCloud a recent function can do some neat tricks beyond the obvious. For example: Wrappers such as Style and Rotate passed ...
Vitaliy Kaurov's user avatar
10 votes

How to call Mathematica from $ \rm\LaTeX $?

You can use Splice, which has been superseded by FileTemplate since v10. [ As of 12.1 Splice...
evanb's user avatar
  • 5,864
10 votes
Accepted

Compare two texts and find differences and similarities

If we consider the applications of Bag-or-words and/or Linear vector space models for doing Natural language processing adequate -- meaning we ignore the sequential order of the words -- then we can ...
Anton Antonov's user avatar
10 votes
Accepted

MaTeX shadow option?

MaTeX returns plain Graphics, usually with some FilledCurve inside. You can disassemble it ...
Szabolcs's user avatar
  • 232k
10 votes
Accepted

How do I test that a string is a sentence?

Mathematica has the experimental (as of v12) function TextStructure which provides some guidance with this question, but things get tricky. ...
bobthechemist's user avatar
9 votes
Accepted

Wordcloud creates a messy image

I find a decent result by using the two-argument version of WordSpacings, where the first number is along the word's direction (horizontal here) and the second is ...
Jason B.'s user avatar
  • 67k
9 votes
Accepted

how to export data as text file

I am not sure of the best way but here is one method. As I understand it you don't want scientific notation. abc = RandomReal[{0, 1}, {3, 2}]*10^-9 Convert the ...
Jack LaVigne's user avatar
  • 14.4k
9 votes

Qubit passing through quantum gate animation

Going off WReach's clever transition, here are a couple of alternative transitions. These transitions all have a sort of "sharpness" parameter, so I've put them in a ...
Musang's user avatar
  • 1,008
9 votes

Simple method to sort versions

SortBy[ PadRight[#, 3] & @* StringCases[n : DigitCharacter .. :> ToExpression[n]] ] @ versions // Reverse
Kuba's user avatar
  • 136k
9 votes

Working with text in 3D graphics

You could always just Texture your Text in: ...
M.R.'s user avatar
  • 31k
9 votes
Accepted

How stack text over an arrow

You could try: mappingArrow[text_] := Underscript[text, Style[RawBoxes@"\[RightArrow]", 20]] For example: ...
Carl Woll's user avatar
  • 129k

Only top scored, non community-wiki answers of a minimum length are eligible