main_testing1/drumb.scala
changeset 363 e5c1d69cffa4
parent 347 4de31fdc0d67
child 402 de59aa20a1dc
equal deleted inserted replaced
362:1bde878ba6c9 363:e5c1d69cffa4
   165   compound_yield(get_deltas(get_prices(portfolio, years)), start_balance, 0)
   165   compound_yield(get_deltas(get_prices(portfolio, years)), start_balance, 0)
   166 }
   166 }
   167 
   167 
   168 
   168 
   169 
   169 
       
   170 
       
   171 investment(List("AAPL"), 2000 to 2001, 100)
       
   172 val aapl_prices = get_prices(List("AAPL"), 2000 to 2002)
       
   173 val aapl_deltas = get_deltas(aapl_prices)
       
   174 
   170 //test cases for the two portfolios given above
   175 //test cases for the two portfolios given above
   171 
   176 
   172 //println("Real data: " + investment(rstate_portfolio, 1978 to 2019, 100))
   177 //println("Real data: " + investment(rstate_portfolio, 1978 to 2019, 100))
   173 //println("Blue data: " + investment(blchip_portfolio, 1978 to 2019, 100))
   178 //println("Blue data: " + investment(blchip_portfolio, 1978 to 2019, 100))
   174 
   179