Question: Using R, simulate a price process: Pt=u+Pt-1+et, for t = 1,2,...,T where T=100, et=N(0,sigma^2), u=0.00024 and sigma = 0.013. You may initialize the simulation with
Using R, simulate a price process: Pt=u+Pt-1+et, for t = 1,2,...,T where T=100, et=N(0,sigma^2), u=0.00024 and sigma = 0.013. You may initialize the simulation with P0=100. I'm wondering if the code I wrote is correct and how to initialize with P0=100

1 #Simulate the price process 2 Ppk-functionCn)1 3 eS rnorm meant sd 0.013 Create the error term 4 P
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
