Guest User

Untitled

a guest
Jan 23rd, 2018
114
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
MatLab 0.47 KB | None | 0 0
  1. MU1 = [1 2];
  2. SIGMA1 = [2 0; 0 .5];
  3. MU2 = [-3 -5];
  4. SIGMA2 = [1 0; 0 1];
  5. X = [mvnrnd(MU1,SIGMA1,1000);mvnrnd(MU2,SIGMA2,1000)];
  6.  
  7. options = statset('Display','final');
  8. obj = gmdistribution.fit(X,2);
  9.  
  10. => file named gmdistrib.m:
  11.  
  12. ??? Error using ==>
  13. gmdistribution.subsref at 45
  14. Static method 'fit' must be called by
  15. using the class name 'gmdistribution'.
  16.  
  17. Error in ==> gmdistrib at 8
  18. obj = gmdistribution.fit(X,2);
  19.  
  20. => file name gmdistribution.m -> works as expected
Add Comment
Please, Sign In to add comment