Skip to content
Discussion options

You must be logged in to vote

Dear @ammaralwandi97 ,
Berikut kami lampirkan kode contoh implementasi untuk membuat lineplot, barplot, histogram, dan boxplot.

# 1. Lineplot: pergerakan harga Close AAPL, GOOGL, dan TSLA 

tesla = stock['Close']

# plot data
plt.plot(tesla.index, tesla['AAPL'], label="Saham Apple")
plt.plot(tesla.index, tesla['GOOGL'], label="Saham Google")
plt.plot(tesla.index, tesla['TSLA'], label="Saham Tesla")
# mengatur legend, title, xlabel, ylabel
plt.legend(loc="upper left")
plt.xlabel('Waktu')
plt.ylabel('Harga Close')
plt.title('Perbandingan Harga Close Saham AAPL, GOOGL, dan TSLA Januari 2018 - November 2023', fontweight="bold")
# 2. Barplot: perbandingan CoV

# mengambil nilai coefficient of …

Replies: 3 comments

Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Answer selected by ammaralwandi97
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
DWV Data Wrangling and Visualization Python Python Programming Language
4 participants