BookmarkSubscribeRSS Feed
genius99
Calcite | Level 5

I have been given this task below can someone help me understand what I have to do?

 

You are considering taking out a loan that requires monthly payments. The loan is $10000 and has simple interest of 0.25% per month.  Your payment is $100 per month.  Create data steps that will calculate the following:

  1. Your loan balance after 10 payments.
  2. The number of payments you’ll need to make until the loan is paid off.
  3. The number of payments you’ll need to make if you increase the payment to $125 every other month (starting with 2nd month).

For each, show for each month, the starting loan balance for the payment, the interest charge (calculated before the payment), the payment amount, and the ending balance.

 

I have loaded all the data sets

/* Load Orders Data */
data work.orders;
  infile "C:/Users/100355202/Desktop/Orders(3).txt" dsd dlm="09"x firstobs=2;
  input OrderID CustomerID $ EmployeeID 
        OrderDate :mmddyy10. RequiredDate :mmddyy10. ShippedDate :mmddyy10.
        ShipVia Freight ShipName :$100. ShipAddress :$100. ShipCity :$100. ShipRegion :$100. 
        ShipPostalCode :$100. ShipCountry :$100.;
  format OrderDate mmddyy10. RequiredDate mmddyy10. ShippedDate mmddyy10.;
run;

/*Load Order Details data */
data work.orderdetails;
  infile "C:/Users/100355202/Desktop/OrderDetails(1).txt" dsd dlm="09"x firstobs=2;
  input OrderID ProductID UnitPrice Quantity Discount;
run;

 

2 REPLIES 2
Astounding
PROC Star

Just to get you moving ...

 

It's good that you know how to load your data sets.  But those data sets are not related to the questions you have to solve.

 

Here's a beginning:

 

data test;
   balance = 10000;
   balance = balance * 1.0025 - 100;
run;

This math computes the remaining balance after 1 month.  Now it's up to you to figure out how to extend the logic for multiple months.

genius99
Calcite | Level 5

does this calculate the Balance after 10 payments?

 

hackathon24-white-horiz.png

The 2025 SAS Hackathon has begun!

It's finally time to hack! Remember to visit the SAS Hacker's Hub regularly for news and updates.

Latest Updates

SAS Enterprise Guide vs. SAS Studio

What’s the difference between SAS Enterprise Guide and SAS Studio? How are they similar? Just ask SAS’ Danny Modlin.

Find more tutorials on the SAS Users YouTube channel.

SAS Training: Just a Click Away

 Ready to level-up your skills? Choose your own adventure.

Browse our catalog!

Discussion stats
  • 2 replies
  • 1108 views
  • 0 likes
  • 2 in conversation