Dear matlab users
i have a matrix of 1511×65 double called x. it has 1511 rows and 65 columns…each column is representing a customer and the 1511 represnts 63 days of power usage with 1 hour for each data obtained. so 1511 / 24 = 63 days.
i made this code to make a graph for each or total of the customers with 24 hours of each customer. Meaning: u will see at clock 3 pm there will be alot of data on 1 row all occured in that time line but different day.
tid = [0:23]';n = 0;while(n<2) %%control how much of the data you wanna plot
n = n + 1; for i=1:size(x,2) k = x(:,n); trow = 24; tcol = ceil(length(x)/trow); k1 = [k;0]; k1 = reshape(k1,trow,tcol); k1 = mean(k1,2); %%taking the mean of the current chosen data from while loop
% plot(tid,k1)
% hold on
endend
The first Question is now: it all works..but HOW do i make it so it creates 1 column for each of the customer for 24 hours…so the matrix in end is: 24×64.
the second question: what if i wanted to filter out weekends out of the data set and work seperately with week days and weekends.
i include hereby the data called x.
thanks for help
Best Answer