19,303 reputation
14286
bio website
location
age
visits member for 2 years, 10 months
seen 51 mins ago

Frequently Asked Questions

WReach? Is that connected to WRI somehow?

The "WR" in my name has nothing to do with the company that develops Mathematica. It is just a coincidence.

Why do you start all your global variable names with $?

I use dollar signs for ad hoc global variables because I have been bitten too many times by accidentally assigning an own-value to a symbol that I happen to use, for example, in a symbolic equation. So I am in the habit of writing $x instead of x. I stick to that convention even for longer symbols like $initialUrl. Just like the regular symbol convention, Mathematica's predefined global symbols all start with a capital letter after the $. My ad hoc symbols always start with a lower case letter, so there is no conflict.

Why do you put semicolons and commas at the beginning of the line instead of at the end like a normal person?

I don't think of it that way. Rather, I switch from horizontal to vertical layout when a single expression is too long to fit on one line. This has the interesting side-effect of making the important delimiters stand out and line up. I first ran into this practice in the SQL community. SQL "programs" have the unpleasant property that they must be written as a single statement -- even if that statement is a hundred lines long (or more!). Sometimes Mathematica expressions share that property.


Oct
16
answered Listable functions thread over Associations; is this documented?
Oct
16
answered How can I evaluate only a single step of a recursive function?
Oct
15
comment How can I evaluate only a single step of a recursive function?
Related question: How do I evaluate only one step of an expression? Mr.Wizard's answer is particularly nifty, although it won't work unmodified for the present question due to the vagaries as to what exactly constitutes "one step".
Oct
14
answered Odd problem with Module
Oct
14
comment Odd problem with Module
If you have the Suggestions Bar turned on, does it make any difference if you turn it off? There have been reports of the Suggestions Bar mangling output.
Oct
13
comment Error when implementing StartProcess[] in loops (Do, While, Table)
+1. With respect to the stream names... I would agree if the stream names were simply "Input" and "Output". But I would argue that the qualifier Standard in "StandardInput" implies that it is being seen from the perspective of the process. After all, Mathematica's own stdin and stdout streams play no role here (i.e. brand new streams are created for the connection). However, what is done is done. It would be harmful to change it now. Perhaps it would make a fine addition to the Possible Issues section of the documentation :)
Oct
13
answered DownValue assignment using Apply
Oct
12
comment How can I determine the Parameters of URLFetch?
Related question: How to manipulate web pages on Mathematica?.
Oct
12
revised Error when implementing StartProcess[] in loops (Do, While, Table)
added the sidebar about the _stdin_/_stdout_ confusion in `ProcessConnection`
Oct
11
revised Error when implementing StartProcess[] in loops (Do, While, Table)
elaborated upon the cause
Oct
11
revised Error when implementing StartProcess[] in loops (Do, While, Table)
added 1 character in body
Oct
11
comment Error when implementing StartProcess[] in loops (Do, While, Table)
Note: I tested this on Windows 7, which exhibited the problem as well albeit at a much higher iteration count. I expect the solution to be the same on MacOSX, but I am not in a position to test it directly myself at the moment.
Oct
11
answered Error when implementing StartProcess[] in loops (Do, While, Table)
Oct
10
answered How to make several DateListPlot have the same scale?
Oct
9
answered Non sequitur in documentation of MemberQ
Oct
8
revised Dataset seems unable to handle ListDensityPlot and ListContourPlot
added the note about Dataset wrapper definitions
Oct
8
answered Dataset seems unable to handle ListDensityPlot and ListContourPlot
Oct
5
comment Replacing columns of a matrix with zeros
+1 If the OP's goal is to leave everything in the original code unchanged except m | n, then I suggest zeroColumns[mat_, m_ ;; n_] := ReplacePart[mat, {_, i_ /; m <= i <= n} -> 0].
Oct
1
comment How a novice user better understand the Q/A
You might find this wiki question useful, especially this answer and this answer.
Sep
30
awarded  Explainer