Re: Plot Random Walk!
- To: mathgroup at smc.vnet.net
- Subject: [mg34398] Re: Plot Random Walk!
- From: "milkcart" <milkcart at m17.alpha-net.ne.jp>
- Date: Sat, 18 May 2002 03:51:00 -0400 (EDT)
- Sender: owner-wri-mathgroup at wolfram.com
Hi Andrea
Thank you for showing me the way to plot graphs of Random walk path.
You can draw a figure with two graghs as follows.
DisplayFunction controle output of Plot.
In[1]:=
RandomWalk[n_, i_] := NestList[#1 + (-1)^Random[Integer] & , 0, n]
In[2]:=
a = Table[ListPlot[RandomWalk[200, i], PlotJoined -> True,
DisplayFunction -> Identity], {i,1, 2}]
In[4]:=
Show[a, DisplayFunction ->$DisplayFunction]
*****************
milkcart
milkcart at m17.alpha-net.ne.jp
**************************