Question: From this question, you will see that the first principal componet represent the average yield rates of all maturities. (1 point) Create a variable mean

From this question, you will see that the first principal componet represent the average yield rates of all maturities.

(1 point) Create a variable mean for the row means of df.

(1 point) Create a figure that includes two line graphs for pc1 and mean over date.

(1 point) Print out the correlation coefficient between pc1 and mean to five decimal places.

(2 point) Describe the meaning of PC1. On the last line of your code, write your response as a commented test as follows.

Your code here # Your interpretation here

The graph for Part 2 must be as follows:

Hint: Replace the ????? part with your solution.

mean = df.?????(axis=?????) fig = plt.figure(figsize=(15, 10)) plt.plot(?????, ?????, label='?????') plt.plot(?????, ?????, label='?????') plt.legend(loc="upper right") plt.grid() plt.show() print('Correlation between pc1 and mean is',np.round(?????,?????)) 

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!