Python Interview Questions for data analyst interview
Question 1: Find the top 5 dates when the percentage change in Company A's stock price was the highest.
Question 2: Calculate the annualized volatility of Company B's stock price. (Hint: Annualized volatility is the standard deviation of daily returns multiplied by the square root of the number of trading days in a year.)
Question 3: Identify the longest streaks of consecutive days when the stock price of Company A was either increasing or decreasing continuously.
Question 4: Create a new column that represents the cumulative returns of Company A's stock price over the year.
Question 5: Calculate the 7-day rolling average of both Company A's and Company B's stock prices and find the date when the two rolling averages were closest to each other.
Question 6: Create a new DataFrame that contains only the dates when Company A's stock price was above its 50-day moving average, and Company B's stock price was below its 50-day moving average
I have curated the best interview resources to crack Python Interviews 👇👇
https://topmate.io/analyst/907371
Hope you'll like it
Like this post if you need more resources like this 👍❤️
#Python
Question 1: Find the top 5 dates when the percentage change in Company A's stock price was the highest.
Question 2: Calculate the annualized volatility of Company B's stock price. (Hint: Annualized volatility is the standard deviation of daily returns multiplied by the square root of the number of trading days in a year.)
Question 3: Identify the longest streaks of consecutive days when the stock price of Company A was either increasing or decreasing continuously.
Question 4: Create a new column that represents the cumulative returns of Company A's stock price over the year.
Question 5: Calculate the 7-day rolling average of both Company A's and Company B's stock prices and find the date when the two rolling averages were closest to each other.
Question 6: Create a new DataFrame that contains only the dates when Company A's stock price was above its 50-day moving average, and Company B's stock price was below its 50-day moving average
I have curated the best interview resources to crack Python Interviews 👇👇
https://topmate.io/analyst/907371
Hope you'll like it
Like this post if you need more resources like this 👍❤️
#Python