Questions on the manipulation of String objects in Mathematica, and the functions used for these manipulations.

learn more… | top users | synonyms (4)

3
votes
1answer
61 views

How can I lookup the grammatical type of a word?

It seems WordData isn't complete: ...
12
votes
0answers
115 views

Can Mathematica convert a RegularExpression into a StringExpression or vice-versa?

I know that Mathematica can perform string comparison using either StringExpression or RegularExpression. Although regular ...
5
votes
0answers
57 views

SimilarityRules for SequenceAlignment of two lists

I am trying to use the SimilarityRules option of SequenceAlignment to customize its output. This works perfectly for strings, ...
4
votes
0answers
86 views

Error with String patterns producing Removed[“$$Failure”]

While working on How to capitalize the first letter of each word in a string and trying to understand why certain characters were not considered letters I tried this: ...
3
votes
0answers
50 views

Why was StringRepeat designed so that StringRepeat[s, 0] throws an error?

I'm wondering about the rationale behind the design decision that leads to the following expression throwing an error: ...
3
votes
0answers
55 views

Error when combining Except, “*” and an additional character

Anyone knows why StringMatchQ["x", Except[{"1", "2"}]] StringMatchQ["x", Except[{"*"}]] StringMatchQ["x", {"1", "*"}] (* without Except *) all work as ...
3
votes
0answers
84 views

Copy string with markup so it looks good on input

How can I copy a string with a bunch of *Box expressions without it blowing up into the raw expression? ...
2
votes
0answers
101 views

How to efficiently find parts of a string with beginning and ending specified?

I'm trying to find specific URL addresses from a html document. The addresses can be found between the strings "href=\"" and "\" class=\"listing". The problem is not including strings like this: ...
2
votes
0answers
128 views

Read in bezier curve from svg file

I am trying to do some calculation of some svg file,After read in with Import["filename","XML"]and some easy operation, I can get the string of the bezier curve, ...
1
vote
0answers
55 views

Using \n (new line) as delimiter in StringSplit

While trying to build my own simple C-language highlighter for strings in Mathematica (see here for a very sophisticated highlighter generator package by Leonid Shifrin) I came upon the issue of using ...
1
vote
0answers
44 views

Where can I find documentation on use of special characters in templates?

I am new to Templates. I have seen the usage "\!\(\*StyleBox ...)" as here: disabling templates What does the string "!(*" accomplish and can I find some ...
1
vote
0answers
87 views

Geodesy without units?

Suppose I'm interested in the latitude of Los Angeles and I do the following: ...
0
votes
0answers
41 views

Constant Strings?

I am writing a workbook to compute double integrals, and in order to graph the function in polar/cylindrical form, I have to make a substitution in the original formula. How can I have the original ...
0
votes
0answers
78 views

How to parse fraction to a number?

Considering a fraction: val = "F \!\(\*FractionBox[\(1\), \(1\)]\)"; I extract the part of interest: ...
0
votes
0answers
73 views

Shortest Common Superstring for all k-length strings on an alphabet

Given all strings of length $k$ of an alphabet of size $n$. This gives $n^{k}$ strings. Now I want to create one superstring that contains all these strings as substrings. They hopefully strongly ...
0
votes
0answers
112 views

importing a file with asterisk in its name (Linux machines)

I am trying to import a file: ...
0
votes
0answers
46 views

StringCount in Mathematica

StringCount["one letters three letters letters one letters letters three letters", "one" ~~ __ ~~ "three"] gives 1 because ...
-1
votes
0answers
78 views

Problem with System.Array in Mathematica

i am using NETLink to use some COM Objects in Mathematica, it works fine with almost all the functions, except one, that function has the following sintax in VB: Compute_CurrentPlan(nmsg As Long, ...
-6
votes
0answers
50 views

rename files randomly

I need to read a directory with pdf files, rename them by numerical sequence of 8 digits when lifting with pdf extension, and then record the result (the idea is that they are totally random names ...