Questions relating to working with textual information: textual analysis, data mining, etc.

learn more… | top users | synonyms

2
votes
3answers
148 views

Remove pieces of a text file

I have imported a text file as a Table with testpbkg = Import["unweighted_events.lhe", "Table"] The file looks like this. I want just to select the text ...
6
votes
1answer
202 views

How to type sentences into Mathematica

I am writing a paper and in conjunction with the paper I want to submit a Mathematica file that shows the numerical calculations. But I want it to follow in order of the paper. I know this is ...
2
votes
0answers
50 views

Finding position of text returned with `TextRecognize`

I am trying to extract data from images (using some of the methods presented in [1524]), and would like to have a way to selectively cover/remove text from axes and legends. ...
2
votes
1answer
148 views

Complete and utter nonsense with Overlay and Graphics

I'm trying to simply overlay some text and a scalebar onto an image. I'm getting (what I perceive to be) completely ridiculous results while trying to do this. Here's the code: ...
4
votes
1answer
73 views

Classifying text and number features

I am new to the ML algorithms and I am checking the Classify function of Mathematica. I understand the math for the random forest algorithm, but I have a question ...
0
votes
0answers
38 views

Plot markers appear off-centre [duplicate]

Before I start I should mention that this question has been posted in another form here, Point Renderings Slightly Off in Mathematica. However my case is slightly different in that I do not use ...
0
votes
2answers
52 views

How do I add the nth element for every line in a text file?

Suppose I have a text file, in this format: ...
2
votes
1answer
70 views

Using Mathematica to batch-produce text files

I need to make a bunch of plaintext files, all of which differ only in a single parameter. The text I want to "copy" or "batch produce" is a little bit complex, since it contains quoted areas and ...
2
votes
1answer
54 views

Export of all notebook files as text files

I want to export all my notebook files located in a root directory as text files. Below is a simple code that I use. Ho can I export "only" the necessary text content of each notebook file? ...
12
votes
1answer
136 views

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

I want to use the underbrace "esc u{ esc" but have it placed underneath text. Like $$\underbrace{g...g}_{n-times}$$ in a mathematica text cell. Is it possible? Thanks
3
votes
1answer
109 views

Problem with deleting words from text [closed]

The task I need to do is to import a text book from here http://www.gutenberg.org/cache/epub/36/pg36.txt, then drop the last 20000 words from it and determine how many times the remaining words occur. ...
6
votes
1answer
95 views

Wordcloud creates a messy image

I'm trying to use Wordcloud built in function (I'm using v10.3.0.0) but the result is not good. I'm using a list with expressions and respective weights: ...
3
votes
1answer
34 views

Skipping commented in a stream from OpenRead

Is there a solution to skip comments in text files that are imported with OpenRead? I know there are solutions for Importand <...
5
votes
1answer
40 views

How to specify the text size of a vertex index in a 3D mesh using Labeled

My code takes a list of {x, y, z} vertices and displays a convex hull with each vertex labeled by its index in the list. Here is a minimal working example of the ...
4
votes
2answers
193 views

In a list, exclude words that use too many specific letters

Trying to re-rwite for clarity. Referring to my previous lists: I would like to trim a dictionary so that all words that "consume" more than n letters "x" are ...
8
votes
1answer
97 views

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

Function WordCloud can take such options as WordOrientation and ColorFunction. It is not ...
3
votes
1answer
75 views

How to align text to left and output to right, in manipulate?

I need to show a layer of information on a 3D graphics, inside a manipulate box. Currently, all the code is working great, except that the text should be aligned to the left, while the output numbers ...
1
vote
2answers
57 views

Superscript standalone text

How do I write a superscript text standalone, without implying power? E.g. ToExpression[25]<>"CNTRL+^oC" doesn't format well, italicizing o and leaving whitespace in-between the number and ...
3
votes
1answer
81 views

Finding all Spanish words with given vowel patterns

I'm trying to implement a function using DictionaryLookup that does the following: Uses a Spanish dictionary Lists and counts of all words where the 5 vowels ...
0
votes
0answers
41 views

How to make black text on white background [duplicate]

I have a Georgian black text on "dirty yellow" paper I want to make pdf, black text on white paper . I try I also try to like this... Can anyone help me? Sorry for my English. Thanks!
6
votes
1answer
126 views

Finding quotations in a text

I actually deal with the problem of finding quotations (i.e. "this is a quotation") in larger texts of different languages, mostly German and English. Unfortunately there are several ways to fill text ...
1
vote
1answer
89 views

Resources for bioinformatics or computational biology

I am looking for some textbooks/websites to learn applications of Mathematica to bioinformatics/computational biology. Searching on Amazon and Wolfram books section did not result in any direct hits. ...
5
votes
3answers
195 views

DeleteStopwords in other languages?

I saw that in new version of Mathematica there is an interesting function: DeleteStopwords that deletes stopwords from a list of words, but this function is only ...
2
votes
1answer
119 views

How to set up margins in Mathematica to write a paper

I'm trying to do a problem write-up for my quantum mechanics class and would like use Mathematica, since I'm going to be using matrix mechanics, and it seems like the best way to write a lot of ...
4
votes
3answers
100 views

How create text label of form “var = ”, var properly formatted

If I use z = 99; Row[{TraditionalForm@HoldForm[z == 1], z}] then as output I get a property formatted math expression $z = 199$. How do I accomplish the ...
15
votes
3answers
432 views

Highlighting pattern strings in a large text

I would like to apply Style to strings that are matched, for example, with one or more specified patterns or regular expressions, a string or a list of both, ...
2
votes
2answers
138 views

How to make the label text to negate-color against background

This is current solution from a friend: ...
0
votes
1answer
40 views

Why does WordStem return different results for “abacus” and “abacuses”?

I just noticed the following: WordStem["abacus"] (* abacu *) WordStem["abacuses"] (* abacus *) WordStem["cactus"] (* cactu *) WordStem["cactuses"] (* cactus *) ...
28
votes
1answer
340 views

How to speed up TextJustification in Mathematica 10

Based on this question: - Version 7 print environment - I set up two 10 page test documents in version 7.0.1 and version 10.1. The version 7 document exported to PDF in 4.18 seconds whereas the ...
1
vote
1answer
97 views

How hard is it to export numbers that can be used in other programs? [duplicate]

I am calculating a few lists of values that I have in arrays. I want to export these into a tab-delimited text file that I can import into other programs for analysis, plotting and so on but I am ...
4
votes
2answers
154 views

Printing every other line from input text

I am trying to do some text manipulation in Mathematica. After importing a text file (in.txt) as a string, how would you then output every other line? In the ...
2
votes
1answer
64 views

Import tabular text data

I have a text file created with a bash script I wanted to read the data avoiding the first line. I have written few dirty codes, but I wondered if anybody can do it in fewest possible nice one ...
6
votes
1answer
101 views

Searching for literal strings with TextSearch

The documentation indicates that TextSearch can be used to look for a "literal string" inside documents, but it appears Mathematica may be applying a regex-style ...
3
votes
2answers
53 views

How to get highlighted text from event

I want to do the following: Given a text in a Mathematica dynamic module "at runtime". If some text is selected with the cursor/mouse, after the mouse button release, get the selected text. Thank ...
6
votes
1answer
170 views

Using Padding with Text and Style

Suppose that I use: Text[Style["(1, 0, 0)", 12, Background -> White], {1, 1, 0}] How can I put a few points of padding around the text? Thanks to Jens: ...
1
vote
1answer
65 views

Show scientific form number in Epilog on a plot

I'd like to overlay a scientific form number on a ListPlot at a particular position. Simply using ...
11
votes
1answer
190 views

Accessing figure style (oldstyle or lining) of TrueType fonts

Most professional fonts come with at least two figure styles: old style (or text) figures and lining figures. In plots and most other figures I prefer to use lining figures. This is no problem with ...
1
vote
2answers
249 views

Plotting data from multiple text files

I'm new to mathematica and stack exchange, so any help would be appreciated. I want to plot a bunch of data from text files that contain a lot of extraneous data. I have a hundred files with different ...
3
votes
2answers
124 views

How to show and hide text by a button

I'm trying to implement a button that can show and hide output text in a panel/tab, but I can't find a specific command to do that. I tried StringReplace, but it doesn't work for me.
17
votes
2answers
411 views

Parenthesize what I have highlighted

I want to highlight a piece of equation, click a button and have that part taken into parentheses.
2
votes
0answers
23 views

How to make lines not wrapping in text-mode Mathematica? [duplicate]

When running Mathematica from Unix command line, i.e. pure text mode, the lines wrap at about 70 pr 80 characters, creating lots of visual clutter. How do I set it so that any outputs will not wrap ...
3
votes
2answers
160 views

Alignement of text

I adopted the following clever code from Mr. Wizard (see here ). HoldForm[+##] & @@ RandomInteger[100, 2] I want to prepare a practising table of addition ...
4
votes
1answer
607 views

How to make new line in mathematica file output?

I know that new line is classically made by "\n". I want to make a string with lines of data and then export it into a file: ...
0
votes
1answer
190 views

Formatting an equation: X^Y to pow(X,Y)

I am trying to solve for the intersection of two circles with arbitrary centers and arbitrary radii. ...
2
votes
0answers
128 views

Transforming/exporting text to image

I have a string in a .txt which I process as follow: ...
1
vote
0answers
56 views

Mysterious message posted when I move the cursor in a custom function

I wrote a function called CPlot for complex plotting which is supposed to act a lot like Plot in its input format, but ever ...
9
votes
1answer
448 views

How can I replace the Greek symbols in an expression with their plain text names?

Suppose I have an expression with Greek symbols in it. How would I convert that expression to another expression where the Greek symbols have been replaces with their names in plain text? I've ...
4
votes
1answer
402 views

problem exporting eps figures since mathematica 10

I am having trouble when exporting eps figures since I have upgraded to mathematica 10.0 in linux. Basically the text in the frame label and in the frameticks come out bad. The letters are much to ...
0
votes
2answers
120 views

How to convert cube root of this equation into TeX?

When I solve the equation $$\sqrt[3]{-3 x+6}+\sqrt[3]{2 x+4}+\sqrt[3]{x-10}=0$$ I used ...
3
votes
1answer
203 views

Keeping Font Relative Size to Object/Graphics/Plot Object upon Resize

I want to keep the text generated within a graph/plot to remain the same relative to an element (a disk of size 0.2) of the image upon resize, not the image itself, while maintaining the original ...