calling a function in another function by changing only few input arguments
Show older comments
I have written a function function
[ yp,PAC ] = PAgent( c5,c6,c7,rcapa,Aineq5,Bineq5,Aeq5,Beq5,lb,ub,options )
suppose if i have to call this function in another function by changing only the input argument 'rcapa', i.e., other input arguments c5,c6,c7.... will not change, but only 'rcapa' changes, can i write like the following,
PA1 = @(rcapa) PAgent([],[],[],rcapa,[],[],[],[],[],[],[] );
[yp1,PAC1]= PA1(rcapa);
Accepted Answer
More Answers (0)
Categories
Find more on Software Development Tools in Help Center and File Exchange
Products
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!