<SYSTEM_TASK:>
Given the following text description, write Python code to implement the functionality described below step by step
<END_TASK>
<USER_TASK:>
Description:
 Simple Rate of Return
$$
\frac{P_1 - P_0}{P_0} = \frac{P_1}{P_0} - 1
$$
Adj Close is "Adjusted close price", adjusted by dividends and other events at the close of the market at that date.
Step1:  Logarithmic Return
$$
ln(\frac{P_t}{P_{t-1}})
$$
<ASSISTANT_TASK:>
Python Code:
BRK['simple_return'] = (BRK['Close'] / BRK['Close'].shift(1)) - 1
print(BRK['simple_return'])
BRK['simple_return'].plot(figsize=(8,5))
plt.show()
avg_returns_d = BRK['simple_return'].mean()
avg_returns_d
avg_returns_a = avg_returns_d * 250 # multiply by the average number of business days per year
print(str(round(avg_returns_a, 5) * 100) + ' %')
Explanation: Simple Rate of Return
$$
\frac{P_1 - P_0}{P_0} = \frac{P_1}{P_0} - 1
$$
Adj Close is "Adjusted close price", adjusted by dividends and other events at the close of the market at that date.
End of explanation
BRK.head()
BRK['log_return'] = np.log(BRK['Close'] / BRK['Close'].shift(1))
print(BRK['log_return'])
BRK['log_return'].plot(figsize=(8, 5))
plt.show()
log_return_d = BRK['log_return'].mean()
log_return_d
log_return_a = BRK['log_return'].mean() * 250
log_return_a
print(str(round(log_return_a, 5) * 100) + ' %')
Explanation: Logarithmic Return
$$
ln(\frac{P_t}{P_{t-1}})
$$
End of explanation
<END_TASK>