Advertisement
Guest User

Adding Lag to a System

a guest
Apr 23rd, 2017
136
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
MatLab 0.28 KB | None | 0 0
  1. %% Code "Ind_Analysis_Control.m must be ran first to obtain EEG data
  2.  
  3. time=(1:length(EEG))/128;
  4. time=time';
  5. i = 1 ;
  6. while i < 15;
  7.    
  8.     % Incorporate lag in here somehow
  9.    
  10.     [beta,sigma] = mvregress(EEG,time);
  11.    
  12.     i=i+1;
  13. end
  14.  
  15. beta
  16.  
  17. a = EEG*beta;
  18. plot(time,a)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement