npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2024 – Pkg Stats / Ryan Hefner

financialcalculators

v1.0.1

Published

NPM Module that contains all basic financial calculators.

Downloads

3

Readme

Installation

npm i financialcalculators

Usage

const calc = require('financialcalculators')
const result = calc.sipCalculator(1000,12,5);
console.log(result);

OR

const {sipCalculator} = require('financialcalculators')
const result = sipCalculator(1000,12,5);
console.log(result);

Terminologies

  1. p - principal amount
  2. r - rate of interest per annum
  3. n - number of years
  4. cf (optional), (defalut value - 1) - compound frequency (1(yearly)/2(half-yearly)/4(quarterly)/12(monthly))
  5. df (optional),(defalut value - 12) - depositing frequency (1(yearly)/2(half-yearly)/4(quarterly)/12(monthly))
  6. inv[] - array of invested amount upto n years
  7. totalVal[] - array of final corpus amount upto n years
  8. time[] - array of n/12 upto n years
  9. returns - total interest gained
  10. sipAmount - sip amount required
  11. lumpsumAmount - lumpsum amount required
  12. duration - duration required in years
  13. fv - future value
  14. wpm - withdrawals per month

What it contains

  1. sipCalculator(p,r,n,cf) returns an object {inv[], totalVal[], returns, time[]}
  2. lumpsumCalculator(p,r,n,cf) returns an object {inv[], totalVal[], returns, time[]}
  3. goalSipCalculator(fv,r,n) returns an object {inv[], totalVal[], returns, time[], sipAmount}
  4. goalLumpsumCalculator(fv,r,n) returns an object {inv[], totalVal[], returns, time[], lumpsumAmount}
  5. timeDurationSip(fv,r,p) returns an object {inv[], totalVal[], returns, time[], duration}
  6. timeDurationLumpsum(fv,r,p) returns an object {inv[], totalVal[], returns, time[], duration}
  7. swpCalculator(p,wpm,r,n) returns an object {startingBal[], endingBal[], time[]}
  8. ssyCalculator(p,r)[Sukanya Samriddhi Yojna] returns an object {inv[], totalVal[],returns, time[]}
  9. investmentPlanner(salary,age,investmentValue) returns an object {idealInvestment, deficit, equityAmount, debtAmount}
  10. cagrReturnCalculator(initialValue,endingValue,period) returns CAGR value in percentage
  11. absoluteReturnCalculator(initialValue,endingValue) returns Absolute returns value in percentage
  12. emiCalculator(p,r,n) returns an object {emi, totalInterest, totalPayment}
  13. gstExclusiveCalculator(amount,gstRate) returns an object {gst, postGSTAmount}
  14. gstInclusiveCalculator(amount,gstRate) returns an object {gst, preGSTAmount}
  15. inflationFutureValueCalculator(p,r,n) returns future value of inflation
  16. inflationRateCalculator(p,r,n) returns rate of inflation
  17. ruleOf72(rateOfInterest) returns duration in years
  18. ppfCalculator(p,r,n,df) returns an object {inv[], totalVal[], returns, time[]}
  19. liquidityRatio(assets, debt) returns liquidity ratio
  20. budgetCalculator(salary) returns an object {needs, wants, investment}
  21. simpleInterestCalculator(p,r,n) returns an object {inv[], totalVal[], returns, time[]}
  22. compundInterestCalculator(lumpsumAmt,sipAmt,r,n,cf,df) returns an object {sipResult[], lumpsumResult[], totalInvested, totalReturns, totalFutureValue}
  23. retirementCalculator(currentAge,retirementAge,lifeExpectancy,r,annualExpense,inflationRate) returns an object {inv[], totalVal[], returns, time[], sipAmount, corpus, annulaExpenseWithInflation}
  24. fdCalculator(p,r,n,cf) returns an object {inv[], totalVal[], returns, time[]}
  25. rdCalculator(p,r,n) returns an object {inv[], totalVal[], returns, time[]}
  26. childEducationCalculator(currentAge,higherEducationAge,r,presentCostOfEducation,inflationRate) returns an object {inv[], totalVal[], returns, time[], sipAmount}