turn on suggestions

Auto-suggest helps you quickly narrow down your search results by suggesting possible matches as you type.

Showing results for

Find a Community

- Home
- /
- BI
- /
- Enterprise Guide
- /
- counting interest

Topic Options

- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page

- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Highlight
- Email to a Friend
- Report Inappropriate Content

09-29-2014 04:27 PM

Hello friends please help me to count interest rate

I have some discrepancy in counting interest rate with Bank calculator and with SAS

I am counting interest for **$9000.00** @ **2.49%** for **12 month**.

Bank is giving me monthly payment $**760.00** which would be **$9120.00** at end of the 12 months (so basically i am paying 120 more than actual amount)

where as if i use below code i am getting something different...

**data test;**

** capital=9000;**

** interest_rate='2.49%';**

** do month=1 to 12;**

** interest=2.49/100*capital;**

** output;**

** capital+interest;**

** end;**

**run;**

/*12TH OBS WILL BE

11796.113263 | 2.49% | 12 | 293.72322026 |

*/

OR

**data test2;**

** capital=9000;**

** interest_rate='2.49%';**

** do month=1 to 12;**

** interest=capital*.12/12;**

** output;**

** capital+interest;**

** end;**

**run;**

/*

12TH OBS WILL BE

10041.01512 | 2.49% | 12 | 100.4101512 |

*/

is this happening coz of my code is adding interest every time when its counting interest for amount...? if so how can i do "**capital-interest**"

Accepted Solutions

Solution

09-30-2014
01:05 PM

- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Highlight
- Email to a Friend
- Report Inappropriate Content

09-30-2014 01:05 PM

All Replies

- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Highlight
- Email to a Friend
- Report Inappropriate Content

09-29-2014 04:39 PM

Is the interest rate 2.49 per month? Or did you take an annual rate and divide by 12?

In either case you might want to look in the documentation for financial functions. Payment seems to imply that you may be paying down a loan.

Look at:

data want;

payment=mort(9000, ., .0249/12,12);

run;

proc print;run;

This seems to match the bank as a loan of 9000, with annual rate of 2.49% compounded monthly(the /12) for 12 months.

- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Highlight
- Email to a Friend
- Report Inappropriate Content

09-29-2014 04:49 PM

Thanks a lot Ballardw for yr quick response but is there a way i can see payment per month in your case...so basically instead seeing only one obs i want to see 12 obs in your code...

- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Highlight
- Email to a Friend
- Report Inappropriate Content

09-29-2014 06:33 PM

You might need to provide some details as to what you are actually trying to do. If it is a loan repayment then the results of the MORT function I posted are the likely monthly payment, the same value, for each of 12 months. So you could either put the function inside a do loop of month=1 to 12 with an output statement inside the loop or just multiply the result by 12 for a total.

There are other financial functions that you may want to investigate such as CUMIPMT, cumulative interest payment.

Solution

09-30-2014
01:05 PM

- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Highlight
- Email to a Friend
- Report Inappropriate Content

09-30-2014 01:05 PM

- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Highlight
- Email to a Friend
- Report Inappropriate Content

09-30-2014 02:14 PM

Not everyone has ETS though...

- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Highlight
- Email to a Friend
- Report Inappropriate Content

09-30-2014 04:03 PM

Thanks Ballardw and Chris...i got the answer...using ETS and Mort function....