APR Calculator Discord Bot: Compounding Interest Added

in #hive-1679223 years ago

APRCalculatorUpdate.gif


I’m not sure if anybody else is using the APR calculator function I added to our Discord bot last week. But it has at least helped me set up my HBD savings and weekly top-up goals, so the effort to code was worth it. It was possible to calculate it manually, but a Discord bot doing it is much more convenient. 😄


A couple of users have mentioned that it’s better to incorporate compound interest into the bot's calculations. I already thought of it while I was starting to create the function. But then dismissed the idea because there’s already a “weekly top-up” calculation and considered compounded interest less significant. However, after looking at it deeper, I realized I was wrong. Compound interest has a much bigger impact on earnings than I assumed.


So here's version 2.0 of our HivePhBot's APR Interest Calculator.
Check it out on Discord!




Compounding Interest Calculation Update


Compounding happens when the new interest is calculated based on the starting balance and all the previously accumulated interest.

Consider an initial balance or principal amount of 100 HBD. It will earn an interest of 1.64 HBD for its first month. When the compounding option is available, the next interest calculation will use 101.64 HBD (principal plus previous interest), instead of the starting 100 HBD. The next interest earning won’t seem much because it’s only 1.67 HBD, just 0.03 HBD higher than the previous. But the real magic happens when you let compounding do its work for long periods.


Here’s the bot calculation for the APR earnings of a 100 HBD principal over a year with 20% APR. I made it a point to both include the figures for when interest is compounded (left) and when it’s not (right).

image.png

In the second month, there’s only 0.03 HBD interest increase. But when compounded in a year, your 20% APR would yield an extra 1.944 HBD. This is for a 100 HBD balance. If you invest more, then increase on earnings will be much more exciting too.




How to do Compounding in HBD Savings


You may wonder why I calculated compound interest for a month’s duration. It’s because users are only allowed to claim HBD savings interest every 30 days. Whenever a claim is successfully processed, you'd have to wait 30 days to do the next.

After claiming the interest, you’d have to re-invest it by transferring the HBD amount you earned to Savings at the soonest possible time. If you didn’t do this step, then compounding doesn’t happen.

I have yet to explore options on how to automatically do claims of interest and direct transfer to savings. Since my goal is to regularly execute HBD Savings top-ups whenever I get my author rewards, I am not too compelled to look for automatic options. I can do it manually since I’m regularly checking my Hive account.




More Examples of the Impact of Compounding


The !apr command is available to all users of servers with the HiveBotPH Discord bot. You can either type the command on a channel that the bot has access to, or privately send the bot a direct message. Take note that command parameters didn’t change after this update.

!apr STARTING_HBD_BALANCE OPTIONAL_WEEKLY_HBD_TOPUP


Here are more examples highlighting the difference in earnings with and without compounding.


When you start with something as high as 2000 HBD, the gap between the two calculations is really much more prominent.


image.png


And here’s my humbler personal target for my HBD Savings. With around 300 HBD starting balance, I aim to add at least 20 HBD weekly into my Savings. Of course, I’ll make sure to re-invest whatever interest I earn monthly to get that 10+ HBD increase.


image.png


If you have any questions or suggestions, just leave it in the comments section below. Cheers!





Want to earn while having fun? Join Splinterlands.

Like the thumbnail on this post? Make your own using Canva.

Attributions:
----------
Images created with Canva. Cute Discord bot avatar is created with Charat.me. Also, several screenshots from Discord.

Posted Using LeoFinance Beta

Sort:  

Im sure it'll be of great help now...and it has pretty cool features.
It's on the Leofinance discord server??

I'm not on the server, I'll love to test it out for myself ,😩

Thanks for the feedback!

It's a community bot and I only do the code XD So I don't have ownership to where it goes. It's only active in a few servers like OCD's. 😅 And I don't think it's on LeoFinance's discord yet.

Ok I get...I think I'll have to check out OCD I think I'm in their server.

Thanks for the feedback too ❤️

Nice one, @jazzhero . This is a very helpful tool that can encourage more to save and invest in the platform. Good work, man!

!LUV
!PIZZA
!hivebits

Oh you already have that feature, amazing! This certainly helps. Thank you

Posted Using LeoFinance Beta

Thanks for the feedback! The bot was originally a curation helper, but it expanded out of our control. 😅 If you're on HivePH or OCD discords, then you can message the bot to let it calculate APR.

Pleasure :) I read an online calculator being developed and I actually asked if it was possible to add the top up feature and you've already done that through the bot so it's awesome! Will check it out on discord soon.

Posted Using LeoFinance Beta

That web app looks like it'll be a much more comprehensive calculator in the future. Ours is quite limited: the periods are pre-defined and the top-ups are on a weekly basis only.

But if you have any ideas after trying the tool, let me know. No promises, but I'll consider any suggestions related to the APR calc :)

Yes, that's true. Your bot calculator is really cool too. Weekly is okay at least we can have an idea of how the compounded interest would be. I will let you know for sure :) Thank you.

Whoever is directly controlling the V2K told me to kill myself.
They told me if I killed myself now it would save the lives of countless others.
Saying the longer I wait to kill myself the more people will suffer.


They are reckless and should have shown the proper media what they had before taking me hostage for 5 years. I know there are many in prison that dont deserve to be there because of this. Your stay in prison will not be fun @battleaxe and friends. People are going to want you dead when they find out what you did. I hope you die a slow painful death. You sick mother fuckers.

https://peakd.com/gangstalking/@acousticpulses/electronic-terrorism-and-gaslighting--if-you-downvote-this-post-you-are-part-of-the-problem

Its a terrorist act on American soil while some say its not real or Im a mental case. Many know its real. This is an ignored detrimental to humanity domestic and foreign threat. Ask informed soldiers in the American military what their oath is and tell them about the day you asked me why. Nobody has I guess. Maybe someone told ill informed soldiers they cant protect America from military leaders in control with ill intent. How do we protect locked up soldiers from telling the truth?