import pandas as pd
import matplotlib.pyplot as plt

# Sample stock price data
data = {
'Date': ,
'Price':
}

# Convert data to DataFrame
df = pd.DataFrame(data)

# Calculate 50-day moving average
df = df.rolling(window=50).mean()

# Plotting
plt.figure(figsize=(10, 6))
plt.plot(df, df, label='Price')
plt.plot(df, df, label='50-day MA')
plt.xlabel('Date')
plt.ylabel('Price')
plt.title('Stock Price with 50-day Moving Average')
plt.legend()
plt.show()
Feragatname

Bilgiler ve yayınlar, TradingView tarafından sağlanan veya onaylanan finansal, yatırım, işlem veya diğer türden tavsiye veya tavsiyeler anlamına gelmez ve teşkil etmez. Kullanım Şartları'nda daha fazlasını okuyun.