RunThrough

RunThrough["command",expr]

executes an external command, giving the printed form of expr as input and taking the output, reading it as Wolfram Language input, and returning the result.

Details

  • RunThrough writes the InputForm of expr on the standard input for command, then reads its standard output and feeds it into the Wolfram Language.
  • RunThrough starts command, gives input to command, then terminates the input.

Examples

Basic Examples  (1)

Run a Wolfram Language kernel in text mode, having it put a result in a temporary output file:

In[1]:=
Click for copyable input
In[2]:=
Click for copyable input
In[3]:=
Click for copyable input

The result is now in the file:

In[4]:=
Click for copyable input

Delete the temporary file:

In[5]:=
Click for copyable input

See Also

Run  RunProcess  StartProcess  Install  Put  Get

Tutorials

Introduced in 1988
(1.0)