Academic Integrity: tutoring, explanations, and feedback — we don’t complete graded work or submit on a student’s behalf.

Here is a problem, I have to fix with Matlab. There are 5 vlaues. Month, day, ho

ID: 1715681 • Letter: H

Question

Here is a problem, I have to fix with Matlab. There are 5 vlaues. Month, day, hour, demand and price. What I have to do is try to plot it in 2-D by Matlab. As we know, 1 year =12 month = 365 day. 1day= 24 hours. demand and price is diiferent everytime. Those values in excel. 1 month is not equal to 30 day. I mean Jan has 31 days, Feb has 28 years, like that. the code I have right know is

[v,T,vT]=xlsread('vermont_demand_price_2007.csv')

plot(x,y);
cubic_function=spline(x,y);
input =1:1:365;
plot(x,y)
hold on
plot(input,ppval(cubic_function,input),'r')
spline(x,y,7);

data is looks like this.

I just have no idea to make it shows in matlab. Can any one help me?

monthday HourVT demand W) Price (/MWh 53. 44 39. 35 41. 08 48. 54 58. 88 42. 51 41. 01 37. 7 58. 5 791 58. 55 804 62. 26 81660. 22 59 03 590 566 538 534 545 593 653 718 758 12 807

Explanation / Answer

Plot five values in 2-D [v,T,vT]=xlsread('vermont_demand_price_2007.csv') % 'xlsx' for exell 2007 %v: Double %T and vT : cell %use v containing numbers t=v(:,3);y=v(:,5) %if u have to plot second colone depending on first: plot(t,y); cubic_function=spline(t,y); input = .1:.01:10; plot(t,y) hold on plot(input,ppval(cubic_function,input),'r')