Created
          March 8, 2013 19:28 
        
      - 
      
- 
        Save kevin3/5119111 to your computer and use it in GitHub Desktop. 
    commission calculator for two typical online trading platforms for SGX in SGD, Standard Chartered Bank and Lim & Tan Disclaimer: the values calculated work for me but I have noticed the values differ a bit due to rounding 
  
        
  
    
      This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
      Learn more about bidirectional Unicode characters
    
  
  
    
  | #Sample Contract Value | |
| vol=1000 | |
| price=10 | |
| volprice=vol*price | |
| def commSCB(volprice): | |
| "SCB commission is fixed 0.2%" | |
| brokerage=volprice*0.2/100 | |
| clearingfee=0.04/100*volprice | |
| #no SGX trading fee | |
| GST=0.07*(brokerage+clearingfee) | |
| total=brokerage+clearingfee+GST | |
| return total | |
| print "SCB commission $",commSCB(volprice) | |
| def commLT(volprice): | |
| "LimTan online trade commission is 0.28% (up to $50,000) min $25" | |
| commlist=[25,volprice*0.28/100] | |
| brokerage=max(commlist) | |
| clearingfee=0.04/100*volprice | |
| tradingfees= 0.0075/100*volprice | |
| GST=0.07*(brokerage+clearingfee+tradingfees) | |
| total=brokerage+clearingfee+GST | |
| return total | |
| print "LimTan commission $",commLT(volprice) | 
  
    Sign up for free
    to join this conversation on GitHub.
    Already have an account?
    Sign in to comment