How will I reduce the time it takes to calculate data?

2 views (last 30 days)
Hello.
In an excel file I put some data and then I creared a big matrix (1200X2000) on Matlab based on this data. Then I took this matrix and used it to calculate other data. Then I increased the number of data in excel and I made a new matrix (1500X5000). When I used this matrix to calculate what I want Matlab takes too much time. In the code I wrote I have a for loop in another and I think this is responsible for the long time it takes. What change can be made to reduce the time Matlab needs because I still have to use another big matrix (1600X8000). Your help is important.
  2 Comments
Adam
Adam on 15 Jul 2019
Depends entirely what your calculation is. Also
doc profile
is good for understanding exactly what takes time rather than making assumptions.
Guillaume
Guillaume on 15 Jul 2019
1600x8000 is not a particularly big matrix (~97 MB) but of course if you're doing calculation on each element individually it can take some time. Of course, As Adam says it all depends on the codeand whether or not it is well written, so show us that code.

Sign in to comment.

Answers (1)

Stephan
Stephan on 15 Jul 2019

Categories

Find more on Multidimensional Arrays in Help Center and File Exchange

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!