Function is not running. please help me.
2 Ansichten (letzte 30 Tage)
Ältere Kommentare anzeigen
Triveni
am 26 Jul. 2022
Beantwortet: David Hill
am 26 Jul. 2022
I have a program (attached) namely singletradecal.m . When i run it works fine. When i run through function(attached tcfun5.m) it is not running. I think local function withing the function is not running. Please help me fixing the problem.
Trade =[3 3 3 3 4 1 2 4]; %
Q = [ 46 46 46 46 46 46 46 46 ]; %Total Quantity
BP = [ 3500 3600 3700 3700 3800 3800 3700 3500]; % Buy Price
SP = [ 3508.1 4000 3800 3900 4000 3900 3900 3700]; % Sell price
Exch = [1 1 1 1 1 1 1 1];
[NETPL5, CHARGES5, SPOST5, STT5, TVS5, ETC5, IGST5, BROKERAGE5, SEBI5, STAMPDUTY5, DP5, MARGIN5, OCHARGES5, PAYINOUT5] = tcfun5(Q, BP, SP, Trade, Exch)
2 Kommentare
Akzeptierte Antwort
David Hill
am 26 Jul. 2022
Works. Just copy and paste singletradecal into your function or run the script inside the function.
function [NETPL, CHARGES, SPOST, STT, TVS, ETC, IGST, BROKERAGE, SEBI, STAMPDUTY, DP, MARGIN, OCHARGES, PAYINOUT] = tcfun5(Q, BP, SP, Trade)
singletradecal;
end
0 Kommentare
Weitere Antworten (0)
Siehe auch
Kategorien
Mehr zu Transaction Cost Analysis finden Sie in Help Center und File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!