How to switch between parfor and for based on if you have the Parallel Computing Toolbox

8 views (last 30 days)
How can you automatically switch between parfor and for based on if you have the Parallel Computing Toolbox without copying the code within the for loop?

Accepted Answer

Walter Roberson
Walter Roberson on 8 Sep 2015
If there is no PCT installed then parfor is accepted but will operate as a for.

More Answers (0)

Categories

Find more on Loops and Conditional Statements 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!