calling a function in another function by changing only few input arguments
Afficher commentaires plus anciens
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);
Réponse acceptée
Plus de réponses (0)
Catégories
En savoir plus sur Software Development Tools dans Centre d'aide et File Exchange
Produits
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!