3
$\begingroup$

The RandomFunction generates an output in the form of TemporalData. How can I plot a scaled version of this data, e.g., all values divided by $n$ with time kept fixed? I read this post but couldn't find an answer.

$\endgroup$
3
  • 1
    $\begingroup$ s = RandomFunction[BinomialProcess[1/3], {0, 50}]; ListPlot[{s, s["PathStates"]/2}] $\endgroup$ Commented Nov 23, 2015 at 23:45
  • $\begingroup$ @eldo's answer is better $\endgroup$ Commented Nov 24, 2015 at 0:00
  • 3
    $\begingroup$ With direct arithmetic on TemporalData in 10.3, normalization is not necessary: s = RandomFunction[BinomialProcess[1/3], {10, 50}]; ListPlot[{s, s/2}] $\endgroup$
    – Gosia
    Commented Nov 24, 2015 at 0:02

2 Answers 2

3
$\begingroup$
td = RandomFunction[WienerProcess[], {0, 1, .01}, 10];

ListLinePlot[td]

enter image description here

Scaled

ListLinePlot[Normal@td /. {a_, b_} :> {a, b/10}]

enter image description here

$\endgroup$
4
$\begingroup$
td = RandomFunction[WienerProcess[], {0, 1, .01}, 10];

GraphicsColumn[{ListLinePlot[td], ListLinePlot[td/10]}]

Out

$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.