code: def test_to_price_index(df):
      data = df
      rets = data.to_returns()
      actual = rets.to_price_index()
  
      assert len(actual) == len(data)
      aae(actual["AAPL"][0], 100, 3)
      aae(actual["MSFT"][0], 100, 3)
      aae(actual["C"][0], 100, 3)
      aae(actual["AAPL"][9], 91.366, 3)
      aae(actual["MSFT"][9], 95.191, 3)
      aae(actual["C"][9], 101.199, 3)
  
      actual = rets.to_price_index(start=1)
  
      assert len(actual) == len(data)
      aae(actual["AAPL"][0], 1, 3)
      aae(actual["MSFT"][0], 1, 3)
      aae(actual["C"][0], 1, 3)
      aae(actual["AAPL"][9], 0.914, 3)
      aae(actual["MSFT"][9], 0.952, 3)
      aae(actual["C"][9], 1.012, 3)
  
imports: import ffn
  import pandas
  import numpy
  from pytest import fixture
  from numpy.testing import assert_almost_equal
label_desc: Use image node_id 8 for calling a global function with example usage: test_to_price_index(df) without return types